moved pandac imports back to old style

This commit is contained in:
Joe Shochet 2005-05-27 22:50:07 +00:00
parent aa29e67c84
commit 05b6a301d5

View File

@ -19,8 +19,8 @@ DowncastMap = {}
# The type map is used for upcasting and downcasting through # The type map is used for upcasting and downcasting through
# the panda inheritance chain # the panda inheritance chain
def registerInTypeMap(pythonClass): def registerInTypeMap(pythonClass):
from pandac.PandaModules import TypedObject from pandac import TypedObject
if issubclass(pythonClass, TypedObject): if issubclass(pythonClass, TypedObject.TypedObject):
typeIndex = pythonClass.getClassType().getIndex() typeIndex = pythonClass.getClassType().getIndex()
WrapperClassMap[typeIndex] = pythonClass WrapperClassMap[typeIndex] = pythonClass
@ -210,8 +210,8 @@ class FFIExternalObject:
# We create a LineStream for the output function to write to, then we extract # We create a LineStream for the output function to write to, then we extract
# the string out of it and return it as our str # the string out of it and return it as our str
try: try:
from pandac.PandaModules import LineStream from pandac import LineStream
lineStream = LineStream() lineStream = LineStream.LineStream()
self.output(lineStream) self.output(lineStream)
baseRepr = lineStream.getLine() baseRepr = lineStream.getLine()
except AssertionError, e: except AssertionError, e:
@ -229,8 +229,8 @@ class FFIExternalObject:
# Lots of Panda classes have an write or output function defined that takes an Ostream # Lots of Panda classes have an write or output function defined that takes an Ostream
# We create a LineStream for the write or output function to write to, then we extract # We create a LineStream for the write or output function to write to, then we extract
# the string out of it and return it as our repr # the string out of it and return it as our repr
from pandac.PandaModules import LineStream from pandac import LineStream
lineStream = LineStream() lineStream = LineStream.LineStream()
try: try:
# First try the write function, that is the better one # First try the write function, that is the better one
self.write(lineStream) self.write(lineStream)