RNA Types were storing an instance of themself for class introspection and docs but makes freeing the type complicated.

now __rna__ is a PyCObject rather then a BPy_StructRNA instance, to get the rna from python use __get_rna() now.
This commit is contained in:
2009-08-15 05:05:23 +00:00
parent dc952c7f2b
commit 12291b693c
2 changed files with 64 additions and 88 deletions

View File

@@ -313,9 +313,9 @@ def rna2epy(target_path):
structs = []
for rna_type_name in dir(bpy.types):
rna_type = getattr(bpy.types, rna_type_name)
if hasattr(rna_type, '__rna__'):
if hasattr(rna_type, '__get_rna'):
#if not rna_type_name.startswith('__'):
rna_struct = rna_type.__rna__
rna_struct = rna_type.__get_rna()
identifier = rna_struct.identifier
structs.append( (base_id(rna_struct), identifier, rna_struct) )