mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 18:31:55 -04:00
*** empty log message ***
This commit is contained in:
parent
8f338d05a8
commit
d212027cf1
@ -267,6 +267,8 @@ class FFIMethodArgumentTreeCollection:
|
|||||||
|
|
||||||
self.outputOverloadedMethodFooter(file, nesting)
|
self.outputOverloadedMethodFooter(file, nesting)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class FFIMethodArgumentTree:
|
class FFIMethodArgumentTree:
|
||||||
"""
|
"""
|
||||||
Tree is made from nested dictionaries.
|
Tree is made from nested dictionaries.
|
||||||
@ -369,3 +371,16 @@ class FFIMethodArgumentTree:
|
|||||||
indent(file, 0, ('<' + name + '> '))
|
indent(file, 0, ('<' + name + '> '))
|
||||||
indent(file, 0, "'\n")
|
indent(file, 0, "'\n")
|
||||||
|
|
||||||
|
def isSinglePath(self):
|
||||||
|
if (len(self.tree.keys()) > 1):
|
||||||
|
# More than one child, return false
|
||||||
|
return 0
|
||||||
|
else:
|
||||||
|
# Only have one child, see if he only has one child
|
||||||
|
key = self.tree.keys()[0]
|
||||||
|
tree = self.tree[key][0]
|
||||||
|
if tree:
|
||||||
|
return tree.isSinglePath()
|
||||||
|
else:
|
||||||
|
return self.tree[key][1]
|
||||||
|
|
||||||
|
@ -332,7 +332,8 @@ class MethodSpecification(FunctionSpecification):
|
|||||||
# The method body will look something like
|
# The method body will look something like
|
||||||
# panda.Class_destructor(self.this)
|
# panda.Class_destructor(self.this)
|
||||||
self.outputCFunctionComment(file, nesting+2)
|
self.outputCFunctionComment(file, nesting+2)
|
||||||
indent(file, nesting+2, self.typeDescriptor.moduleName + '.'
|
indent(file, nesting+2, 'if ' + self.typeDescriptor.moduleName + ':\n')
|
||||||
|
indent(file, nesting+3, self.typeDescriptor.moduleName + '.'
|
||||||
+ self.typeDescriptor.wrapperName + '(self.this)\n')
|
+ self.typeDescriptor.wrapperName + '(self.this)\n')
|
||||||
|
|
||||||
def outputDestructorFooter(self, methodClass, file, nesting):
|
def outputDestructorFooter(self, methodClass, file, nesting):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user