PyAPI: use bpy_rna_types_capi.c to set type methods

Remove use of '_bpy' as an intermediate module to store functions
which were then assigned in bpy_types.py.
This commit is contained in:
Campbell Barton
2020-05-29 14:50:29 +10:00
parent e115b7b06d
commit 654fde2dd2
9 changed files with 86 additions and 63 deletions

View File

@@ -25,12 +25,7 @@ StructRNA = bpy_types.bpy_struct
StructMetaPropGroup = bpy_types.bpy_struct_meta_idprop
# StructRNA = bpy_types.Struct
bpy_types.BlendDataLibraries.load = _bpy._library_load
bpy_types.BlendDataLibraries.write = _bpy._library_write
bpy_types.BlendData.user_map = _bpy._rna_id_collection_user_map
bpy_types.BlendData.batch_remove = _bpy._rna_id_collection_batch_remove
bpy_types.BlendData.orphans_purge = _bpy._rna_id_collection_orphans_purge
# Note that methods extended in C are defined in: 'bpy_rna_types_capi.c'
class Context(StructRNA):
__slots__ = ()