patch [#25809] Auto-Registration as utility function.

This removes auto-registration, committed by Martin r30961.
Realize this is a contentious topic but Brecht and myself both would rather opt-in registration.

TODO:
- addons need updating.
- class list will be modified to use weakrefs (should have been done for existing system too).
- will move bpy.types.(un)register functions into bpy.utils.(un)register_class, currently including these functions in a type list is internally ugly, scripts which loop over types also need to check for these.
This commit is contained in:
2011-02-10 23:48:22 +00:00
parent 46bb5643b7
commit 4612034cf4
62 changed files with 189 additions and 202 deletions

View File

@@ -369,10 +369,12 @@ def menu_func(self, context):
def register():
bpy.utils.register_module(__name__)
bpy.types.IMAGE_MT_uvs.append(menu_func)
def unregister():
bpy.utils.unregister_module(__name__)
bpy.types.IMAGE_MT_uvs.remove(menu_func)
if __name__ == "__main__":