diff options
Diffstat (limited to 'release/scripts')
62 files changed, 188 insertions, 201 deletions
diff --git a/release/scripts/io/netrender/ui.py b/release/scripts/io/netrender/ui.py index 0581e054dff..1583dee427f 100644 --- a/release/scripts/io/netrender/ui.py +++ b/release/scripts/io/netrender/ui.py @@ -363,16 +363,21 @@ class RENDER_PT_network_output(NeedValidAddress, NetRenderButtonsPanel, bpy.type draw = properties_render.RENDER_PT_output.draw -class NetRenderSettings(bpy.types.IDPropertyGroup): - pass -class NetRenderSlave(bpy.types.IDPropertyGroup): - pass +def addProperties(): + class NetRenderSettings(bpy.types.IDPropertyGroup): + pass -class NetRenderJob(bpy.types.IDPropertyGroup): - pass + class NetRenderSlave(bpy.types.IDPropertyGroup): + pass + + class NetRenderJob(bpy.types.IDPropertyGroup): + pass + + bpy.types.register(NetRenderSettings) + bpy.types.register(NetRenderSlave) + bpy.types.register(NetRenderJob) -def addProperties(): from bpy.props import PointerProperty, StringProperty, BoolProperty, EnumProperty, IntProperty, CollectionProperty bpy.types.Scene.network_render = PointerProperty(type=NetRenderSettings, name="Network Render", description="Network Render Settings") diff --git a/release/scripts/modules/bpy/utils.py b/release/scripts/modules/bpy/utils.py index f83b5ab01e0..9d7b1fe3420 100644 --- a/release/scripts/modules/bpy/utils.py +++ b/release/scripts/modules/bpy/utils.py @@ -100,9 +100,6 @@ def load_scripts(reload_scripts=False, refresh_scripts=False): import traceback import time - # must be set back to True on exits - _bpy_types._register_immediate = False - t_main = time.time() loaded_modules = set() @@ -112,7 +109,6 @@ def load_scripts(reload_scripts=False, refresh_scripts=False): if reload_scripts: _bpy_types.TypeMap.clear() - _bpy_types.PropertiesMap.clear() # just unload, dont change user defaults, this means we can sync to reload. # note that they will only actually reload of the modification time changes. @@ -121,7 +117,6 @@ def load_scripts(reload_scripts=False, refresh_scripts=False): addon_disable(module_name, default_set=False) def register_module_call(mod): - _bpy_types._register_module(mod.__name__) register = getattr(mod, "register", None) if register: try: @@ -132,7 +127,6 @@ def load_scripts(reload_scripts=False, refresh_scripts=False): print("\nWarning! '%s' has no register function, this is now a requirement for registerable scripts." % mod.__file__) def unregister_module_call(mod): - _bpy_types._unregister_module(mod.__name__) unregister = getattr(mod, "unregister", None) if unregister: try: @@ -199,8 +193,6 @@ def load_scripts(reload_scripts=False, refresh_scripts=False): for mod in modules_from_path(path, loaded_modules): test_register(mod) - _bpy_types._register_immediate = True - # deal with addons seperately addon_reset_all(reload_scripts) @@ -367,12 +359,9 @@ def addon_enable(module_name, default_set=True): import bpy_types as _bpy_types import imp - _bpy_types._register_immediate = False - def handle_error(): import traceback traceback.print_exc() - _bpy_types._register_immediate = True # reload if the mtime changes mod = sys.modules.get(module_name) @@ -402,19 +391,13 @@ def addon_enable(module_name, default_set=True): return None # 2) try register collected modules - try: - _bpy_types._register_module(module_name) - except: - handle_error() - del sys.modules[module_name] - return None + # removed, addons need to handle own registration now. # 3) try run the modules register function try: mod.register() except: handle_error() - _bpy_types._unregister_module(module_name) del sys.modules[module_name] return None @@ -426,8 +409,6 @@ def addon_enable(module_name, default_set=True): ext = _bpy.context.user_preferences.addons.new() ext.module = module_name - _bpy_types._register_immediate = True - mod.__addon_enabled__ = True if _bpy.app.debug: @@ -454,7 +435,6 @@ def addon_disable(module_name, default_set=True): mod.__addon_enabled__ = False try: - _bpy_types._unregister_module(module_name, free=False) # dont free because we may want to enable again. mod.unregister() except: traceback.print_exc() @@ -594,3 +574,42 @@ def user_resource(type, path="", create=False): target_path = "" return target_path + + +_register_types = _bpy.types.Panel, _bpy.types.Operator, _bpy.types.Menu, _bpy.types.Header, _bpy.types.RenderEngine + + +def register_module(module): + import traceback + total = 0 + register = _bpy.types.register + for cls, path, line in _bpy_types.TypeMap.get(module, ()): + if not "bl_rna" in cls.__dict__: + total += 1 + try: + register(cls) + except: + print("bpy.utils.register_module(): failed to registering class '%s.%s'" % (cls.__module__, cls.__name__)) + print("\t", path, "line", line) + traceback.print_exc() + + if total == 0: + raise Exception("register_module(%r): defines no classes" % module) + + +def unregister_module(module): + import traceback + unregister = _bpy.types.unregister + total = 0 + for cls, path, line in _bpy_types.TypeMap.get(module, ()): + if "bl_rna" in cls.__dict__: + total += 1 + try: + unregister(cls) + except: + print("bpy.utils.unregister_module(): failed to unregistering class '%s.%s'" % (cls.__module__, cls.__name__)) + print("\t", path, "line", line) + traceback.print_exc() + + if total == 0: + raise Exception("unregister_module(%r): defines no classes" % module) diff --git a/release/scripts/modules/bpy_types.py b/release/scripts/modules/bpy_types.py index 1cb30765bf0..43bd3f4ff26 100644 --- a/release/scripts/modules/bpy_types.py +++ b/release/scripts/modules/bpy_types.py @@ -550,85 +550,33 @@ class Text(bpy_types.ID): import bpy return tuple(obj for obj in bpy.data.objects if self in [cont.text for cont in obj.game.controllers if cont.type == 'PYTHON']) -import collections - +# values are module: [(cls, path, line), ...] TypeMap = {} -# Properties (IDPropertyGroup) are different from types because they need to be registered -# before adding sub properties to them, so they are registered on definition -# and unregistered on unload -PropertiesMap = {} - -# Using our own loading function we set this to false -# so when running a script directly in the text editor -# registers moduals instantly. -_register_immediate = True - - -def _unregister_module(module, free=True): - for t in TypeMap.get(module, ()): - try: - bpy_types.unregister(t) - except: - import traceback - print("bpy.utils._unregister_module(): Module '%s' failed to unregister class '%s.%s'" % (module, t.__module__, t.__name__)) - traceback.print_exc() - - if free == True and module in TypeMap: - del TypeMap[module] - - for t in PropertiesMap.get(module, ()): - try: - bpy_types.unregister(t) - except: - import traceback - print("bpy.utils._unload_module(): Module '%s' failed to unregister class '%s.%s'" % (module, t.__module__, t.__name__)) - traceback.print_exc() - - if free == True and module in PropertiesMap: - del PropertiesMap[module] - - -def _register_module(module): - for t in TypeMap.get(module, ()): - try: - bpy_types.register(t) - except: - import traceback - import sys - print("bpy.utils._register_module(): '%s' failed to register class '%s.%s'" % (sys.modules[module].__file__, t.__module__, t.__name__)) - traceback.print_exc() class RNAMeta(type): - @classmethod - def _register_immediate(cls): - return _register_immediate - def __new__(cls, name, bases, classdict, **args): + import traceback result = type.__new__(cls, name, bases, classdict) if bases and bases[0] != StructRNA: module = result.__module__ - ClassMap = TypeMap - - # Register right away if needed - if cls._register_immediate(): - bpy_types.register(result) - ClassMap = PropertiesMap - # first part of packages only if "." in module: module = module[:module.index(".")] - ClassMap.setdefault(module, []).append(result) + sf = traceback.extract_stack(limit=2)[0] + + TypeMap.setdefault(module, []).append((result, sf[0], sf[1])) return result -class RNAMetaRegister(RNAMeta, StructMetaIDProp): - @classmethod - def _register_immediate(cls): - return True +import collections + + +class RNAMetaIDProp(RNAMeta, StructMetaIDProp): + pass class OrderedMeta(RNAMeta): @@ -685,7 +633,7 @@ class Macro(StructRNA, metaclass=OrderedMeta): return ops.macro_define(self, opname) -class IDPropertyGroup(StructRNA, metaclass=RNAMetaRegister): +class IDPropertyGroup(StructRNA, metaclass=RNAMetaIDProp): __slots__ = () diff --git a/release/scripts/op/animsys_update.py b/release/scripts/op/animsys_update.py index e5eab045e94..9262ff40a37 100644 --- a/release/scripts/op/animsys_update.py +++ b/release/scripts/op/animsys_update.py @@ -701,4 +701,8 @@ if __name__ == "__main__": def register(): - pass + bpy.utils.register_module(__name__) + + +def unregister(): + bpy.utils.unregister_module(__name__) diff --git a/release/scripts/op/fcurve_euler_filter.py b/release/scripts/op/fcurve_euler_filter.py index 0e7f0b69eca..6332bbe309c 100644 --- a/release/scripts/op/fcurve_euler_filter.py +++ b/release/scripts/op/fcurve_euler_filter.py @@ -78,13 +78,12 @@ class DiscontFilterOp(bpy.types.Operator): main(context) return {'FINISHED'} - def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/op/image.py b/release/scripts/op/image.py index ddd04c4e7c3..e1d471f8254 100644 --- a/release/scripts/op/image.py +++ b/release/scripts/op/image.py @@ -195,11 +195,11 @@ class ProjectApply(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/op/mesh.py b/release/scripts/op/mesh.py index 447de04f423..4906fd7fc6c 100644 --- a/release/scripts/op/mesh.py +++ b/release/scripts/op/mesh.py @@ -173,11 +173,11 @@ class MeshMirrorUV(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/op/nla.py b/release/scripts/op/nla.py index d47668d68e3..5711fdf12e5 100644 --- a/release/scripts/op/nla.py +++ b/release/scripts/op/nla.py @@ -175,13 +175,11 @@ class BakeAction(bpy.types.Operator): def register(): - pass - # bpy.types.INFO_MT_mesh_add.append(menu_func) + bpy.utils.register_module(__name__) def unregister(): - pass - # bpy.types.INFO_MT_mesh_add.remove(menu_func) + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/op/object.py b/release/scripts/op/object.py index 8fee6e2166d..92886689972 100644 --- a/release/scripts/op/object.py +++ b/release/scripts/op/object.py @@ -565,11 +565,11 @@ class ClearAllRestrictRender(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/op/object_align.py b/release/scripts/op/object_align.py index 8654fb4db3d..d98fe584c1a 100644 --- a/release/scripts/op/object_align.py +++ b/release/scripts/op/object_align.py @@ -287,11 +287,14 @@ def menu_func(self, context): def register(): + bpy.utils.register_module(__name__) bpy.types.VIEW3D_MT_transform.append(menu_func) def unregister(): + bpy.utils.unregister_module(__name__) bpy.types.VIEW3D_MT_transform.remove(menu_func) + if __name__ == "__main__": register() diff --git a/release/scripts/op/object_randomize_transform.py b/release/scripts/op/object_randomize_transform.py index 8b8070f34bc..ee7a5f98b91 100644 --- a/release/scripts/op/object_randomize_transform.py +++ b/release/scripts/op/object_randomize_transform.py @@ -154,11 +154,14 @@ def menu_func(self, context): def register(): + bpy.utils.register_module(__name__) bpy.types.VIEW3D_MT_transform.append(menu_func) def unregister(): + bpy.utils.unregister_module(__name__) bpy.types.VIEW3D_MT_transform.remove(menu_func) + if __name__ == "__main__": register() diff --git a/release/scripts/op/presets.py b/release/scripts/op/presets.py index 36170fb6283..65653aeee3e 100644 --- a/release/scripts/op/presets.py +++ b/release/scripts/op/presets.py @@ -354,11 +354,11 @@ class WM_MT_operator_presets(bpy.types.Menu): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/op/screen_play_rendered_anim.py b/release/scripts/op/screen_play_rendered_anim.py index 244c3d4b332..579af9b34b3 100644 --- a/release/scripts/op/screen_play_rendered_anim.py +++ b/release/scripts/op/screen_play_rendered_anim.py @@ -147,11 +147,11 @@ class PlayRenderedAnim(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/op/sequencer.py b/release/scripts/op/sequencer.py index e34489b335d..de341bef269 100644 --- a/release/scripts/op/sequencer.py +++ b/release/scripts/op/sequencer.py @@ -135,11 +135,11 @@ class SequencerDeinterlaceSelectedMovies(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": diff --git a/release/scripts/op/uv.py b/release/scripts/op/uv.py index 1b6c036b2d2..83282924b5b 100644 --- a/release/scripts/op/uv.py +++ b/release/scripts/op/uv.py @@ -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__": diff --git a/release/scripts/op/uvcalc_follow_active.py b/release/scripts/op/uvcalc_follow_active.py index a226e234f3a..12895fae1c5 100644 --- a/release/scripts/op/uvcalc_follow_active.py +++ b/release/scripts/op/uvcalc_follow_active.py @@ -251,11 +251,14 @@ menu_func = (lambda self, context: self.layout.operator(FollowActiveQuads.bl_idn def register(): + bpy.utils.register_module(__name__) bpy.types.VIEW3D_MT_uv_map.append(menu_func) def unregister(): + bpy.utils.unregister_module(__name__) bpy.types.VIEW3D_MT_uv_map.remove(menu_func) + if __name__ == "__main__": register() diff --git a/release/scripts/op/uvcalc_smart_project.py b/release/scripts/op/uvcalc_smart_project.py index aaa8583b70f..8cdf593f98d 100644 --- a/release/scripts/op/uvcalc_smart_project.py +++ b/release/scripts/op/uvcalc_smart_project.py @@ -1130,10 +1130,12 @@ menu_func = (lambda self, context: self.layout.operator(SmartProject.bl_idname, def register(): + bpy.utils.register_module(__name__) bpy.types.VIEW3D_MT_uv_map.append(menu_func) def unregister(): + bpy.utils.unregister_module(__name__) bpy.types.VIEW3D_MT_uv_map.remove(menu_func) if __name__ == "__main__": diff --git a/release/scripts/op/vertexpaint_dirt.py b/release/scripts/op/vertexpaint_dirt.py index c5bb4450497..5102c94af69 100644 --- a/release/scripts/op/vertexpaint_dirt.py +++ b/release/scripts/op/vertexpaint_dirt.py @@ -180,11 +180,11 @@ class VertexPaintDirt(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/op/wm.py b/release/scripts/op/wm.py index 38fead4ecf8..cbc9e3cd55f 100644 --- a/release/scripts/op/wm.py +++ b/release/scripts/op/wm.py @@ -816,11 +816,11 @@ class WM_OT_sysinfo(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_animviz.py b/release/scripts/ui/properties_animviz.py index 87925a9d6f4..5f5684f5c89 100644 --- a/release/scripts/ui/properties_animviz.py +++ b/release/scripts/ui/properties_animviz.py @@ -94,12 +94,13 @@ class OnionSkinButtonsPanel(): # NOTE: # The specialised panel types are derived in their respective UI modules +# dont register these classes since they are only helpers. def register(): - pass + pass # bpy.utils.register_module(__name__) def unregister(): - pass + pass # bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_data_armature.py b/release/scripts/ui/properties_data_armature.py index c3d3c358dbe..6550e1bb1ed 100644 --- a/release/scripts/ui/properties_data_armature.py +++ b/release/scripts/ui/properties_data_armature.py @@ -289,11 +289,11 @@ class DATA_PT_custom_props_arm(ArmatureButtonsPanel, PropertyPanel, bpy.types.Pa def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_data_bone.py b/release/scripts/ui/properties_data_bone.py index 336fc5430c6..feca4fc2502 100644 --- a/release/scripts/ui/properties_data_bone.py +++ b/release/scripts/ui/properties_data_bone.py @@ -370,11 +370,11 @@ class BONE_PT_custom_props(BoneButtonsPanel, PropertyPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_data_camera.py b/release/scripts/ui/properties_data_camera.py index 9c4f19b4c51..0f5d4a59bf5 100644 --- a/release/scripts/ui/properties_data_camera.py +++ b/release/scripts/ui/properties_data_camera.py @@ -139,11 +139,11 @@ class DATA_PT_custom_props_camera(CameraButtonsPanel, PropertyPanel, bpy.types.P def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_data_curve.py b/release/scripts/ui/properties_data_curve.py index 85a32236bcc..b26b7140fd2 100644 --- a/release/scripts/ui/properties_data_curve.py +++ b/release/scripts/ui/properties_data_curve.py @@ -396,11 +396,11 @@ class DATA_PT_custom_props_curve(CurveButtonsPanel, PropertyPanel, bpy.types.Pan def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_data_empty.py b/release/scripts/ui/properties_data_empty.py index 9a297eba4af..bb0028efec5 100644 --- a/release/scripts/ui/properties_data_empty.py +++ b/release/scripts/ui/properties_data_empty.py @@ -44,11 +44,11 @@ class DATA_PT_empty(DataButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_data_lamp.py b/release/scripts/ui/properties_data_lamp.py index 9961bf1e77f..55781434763 100644 --- a/release/scripts/ui/properties_data_lamp.py +++ b/release/scripts/ui/properties_data_lamp.py @@ -394,11 +394,11 @@ class DATA_PT_custom_props_lamp(DataButtonsPanel, PropertyPanel, bpy.types.Panel def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_data_lattice.py b/release/scripts/ui/properties_data_lattice.py index ae9e9e6f3a8..6bdb36d3520 100644 --- a/release/scripts/ui/properties_data_lattice.py +++ b/release/scripts/ui/properties_data_lattice.py @@ -89,11 +89,11 @@ class DATA_PT_custom_props_lattice(DataButtonsPanel, PropertyPanel, bpy.types.Pa def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_data_mesh.py b/release/scripts/ui/properties_data_mesh.py index 44080b1ffe5..342204d0e78 100644 --- a/release/scripts/ui/properties_data_mesh.py +++ b/release/scripts/ui/properties_data_mesh.py @@ -355,11 +355,11 @@ class DATA_PT_custom_props_mesh(MeshButtonsPanel, PropertyPanel, bpy.types.Panel def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_data_metaball.py b/release/scripts/ui/properties_data_metaball.py index bbe027c5ea4..cf7aa8c08fd 100644 --- a/release/scripts/ui/properties_data_metaball.py +++ b/release/scripts/ui/properties_data_metaball.py @@ -119,11 +119,11 @@ class DATA_PT_custom_props_metaball(DataButtonsPanel, PropertyPanel, bpy.types.P def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_data_modifier.py b/release/scripts/ui/properties_data_modifier.py index 7a1ea160abc..e93b34fe055 100644 --- a/release/scripts/ui/properties_data_modifier.py +++ b/release/scripts/ui/properties_data_modifier.py @@ -701,11 +701,11 @@ class DATA_PT_modifiers(ModifierButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_game.py b/release/scripts/ui/properties_game.py index 77f4da5d405..2717e315ee8 100644 --- a/release/scripts/ui/properties_game.py +++ b/release/scripts/ui/properties_game.py @@ -510,11 +510,11 @@ class WORLD_PT_game_physics(WorldButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_material.py b/release/scripts/ui/properties_material.py index 6bfebc444b9..82c3e840420 100644 --- a/release/scripts/ui/properties_material.py +++ b/release/scripts/ui/properties_material.py @@ -896,11 +896,11 @@ class MATERIAL_PT_custom_props(MaterialButtonsPanel, PropertyPanel, bpy.types.Pa def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_object.py b/release/scripts/ui/properties_object.py index 72ae26c1de2..30380e2d338 100644 --- a/release/scripts/ui/properties_object.py +++ b/release/scripts/ui/properties_object.py @@ -343,11 +343,11 @@ class OBJECT_PT_custom_props(ObjectButtonsPanel, PropertyPanel, bpy.types.Panel) def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_object_constraint.py b/release/scripts/ui/properties_object_constraint.py index 4f1d121b3fc..4b9c2885277 100644 --- a/release/scripts/ui/properties_object_constraint.py +++ b/release/scripts/ui/properties_object_constraint.py @@ -749,11 +749,11 @@ class BONE_PT_constraints(ConstraintButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_particle.py b/release/scripts/ui/properties_particle.py index 27a9a972154..4bed2e81629 100644 --- a/release/scripts/ui/properties_particle.py +++ b/release/scripts/ui/properties_particle.py @@ -1158,11 +1158,11 @@ class PARTICLE_PT_custom_props(ParticleButtonsPanel, PropertyPanel, bpy.types.Pa def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_physics_cloth.py b/release/scripts/ui/properties_physics_cloth.py index f33804c4c6d..0ac4429c71a 100644 --- a/release/scripts/ui/properties_physics_cloth.py +++ b/release/scripts/ui/properties_physics_cloth.py @@ -217,11 +217,11 @@ class PHYSICS_PT_cloth_field_weights(PhysicButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_physics_common.py b/release/scripts/ui/properties_physics_common.py index ec6ec21fa26..3d854533506 100644 --- a/release/scripts/ui/properties_physics_common.py +++ b/release/scripts/ui/properties_physics_common.py @@ -279,11 +279,11 @@ def basic_force_field_falloff_ui(self, context, field): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_physics_field.py b/release/scripts/ui/properties_physics_field.py index f46f78ca017..8a697806aa1 100644 --- a/release/scripts/ui/properties_physics_field.py +++ b/release/scripts/ui/properties_physics_field.py @@ -217,11 +217,11 @@ class PHYSICS_PT_collision(PhysicButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_physics_fluid.py b/release/scripts/ui/properties_physics_fluid.py index 5cc94c24c80..6385a535a44 100644 --- a/release/scripts/ui/properties_physics_fluid.py +++ b/release/scripts/ui/properties_physics_fluid.py @@ -282,11 +282,11 @@ class PHYSICS_PT_domain_particles(PhysicButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_physics_smoke.py b/release/scripts/ui/properties_physics_smoke.py index 0ca5f03f832..56ddff292d9 100644 --- a/release/scripts/ui/properties_physics_smoke.py +++ b/release/scripts/ui/properties_physics_smoke.py @@ -205,11 +205,11 @@ class PHYSICS_PT_smoke_field_weights(PhysicButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_physics_softbody.py b/release/scripts/ui/properties_physics_softbody.py index 343b198fa84..7d3fa66ed02 100644 --- a/release/scripts/ui/properties_physics_softbody.py +++ b/release/scripts/ui/properties_physics_softbody.py @@ -262,11 +262,11 @@ class PHYSICS_PT_softbody_field_weights(PhysicButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_render.py b/release/scripts/ui/properties_render.py index 99b75b59fdd..5dfed9ccb20 100644 --- a/release/scripts/ui/properties_render.py +++ b/release/scripts/ui/properties_render.py @@ -675,11 +675,11 @@ class RENDER_PT_bake(RenderButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_scene.py b/release/scripts/ui/properties_scene.py index 5085e8d2ab5..d3586c645e6 100644 --- a/release/scripts/ui/properties_scene.py +++ b/release/scripts/ui/properties_scene.py @@ -311,11 +311,11 @@ class ANIM_OT_keying_set_export(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_texture.py b/release/scripts/ui/properties_texture.py index 8063dc92166..05e130fac2d 100644 --- a/release/scripts/ui/properties_texture.py +++ b/release/scripts/ui/properties_texture.py @@ -1024,11 +1024,11 @@ class TEXTURE_PT_custom_props(TextureButtonsPanel, PropertyPanel, bpy.types.Pane def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/properties_world.py b/release/scripts/ui/properties_world.py index 0ab39ce6fdb..fd11f299f34 100644 --- a/release/scripts/ui/properties_world.py +++ b/release/scripts/ui/properties_world.py @@ -268,11 +268,11 @@ class WORLD_PT_custom_props(WorldButtonsPanel, PropertyPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_console.py b/release/scripts/ui/space_console.py index 99ddeb13651..b3bd886d8c5 100644 --- a/release/scripts/ui/space_console.py +++ b/release/scripts/ui/space_console.py @@ -163,11 +163,11 @@ class ConsoleLanguage(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_dopesheet.py b/release/scripts/ui/space_dopesheet.py index 9d6c9830675..9a1acfd76b8 100644 --- a/release/scripts/ui/space_dopesheet.py +++ b/release/scripts/ui/space_dopesheet.py @@ -355,11 +355,11 @@ class DOPESHEET_MT_gpencil_frame(bpy.types.Menu): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_filebrowser.py b/release/scripts/ui/space_filebrowser.py index dea306277f1..2d66bb38637 100644 --- a/release/scripts/ui/space_filebrowser.py +++ b/release/scripts/ui/space_filebrowser.py @@ -75,11 +75,11 @@ class FILEBROWSER_HT_header(bpy.types.Header): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_graph.py b/release/scripts/ui/space_graph.py index 235ed54ef0b..55c4d4cfd94 100644 --- a/release/scripts/ui/space_graph.py +++ b/release/scripts/ui/space_graph.py @@ -242,11 +242,11 @@ class GRAPH_MT_key_transform(bpy.types.Menu): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_image.py b/release/scripts/ui/space_image.py index 464e5bb8cfe..433c12b0620 100644 --- a/release/scripts/ui/space_image.py +++ b/release/scripts/ui/space_image.py @@ -727,11 +727,11 @@ class IMAGE_PT_paint_curve(BrushButtonsPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_info.py b/release/scripts/ui/space_info.py index 9881cb55692..6c392cb9a3d 100644 --- a/release/scripts/ui/space_info.py +++ b/release/scripts/ui/space_info.py @@ -404,11 +404,11 @@ class HELP_OT_operator_cheat_sheet(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_logic.py b/release/scripts/ui/space_logic.py index 44c6f5fd684..54dde61e90a 100644 --- a/release/scripts/ui/space_logic.py +++ b/release/scripts/ui/space_logic.py @@ -90,11 +90,11 @@ class LOGIC_MT_view(bpy.types.Menu): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_nla.py b/release/scripts/ui/space_nla.py index 1921e80035d..13afc97f913 100644 --- a/release/scripts/ui/space_nla.py +++ b/release/scripts/ui/space_nla.py @@ -188,11 +188,11 @@ class NLA_MT_edit_transform(bpy.types.Menu): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_node.py b/release/scripts/ui/space_node.py index 64d833434e5..aaf14813ee5 100644 --- a/release/scripts/ui/space_node.py +++ b/release/scripts/ui/space_node.py @@ -197,11 +197,11 @@ class NODE_PT_properties(bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_outliner.py b/release/scripts/ui/space_outliner.py index 38e749c4a75..219dd1de117 100644 --- a/release/scripts/ui/space_outliner.py +++ b/release/scripts/ui/space_outliner.py @@ -118,11 +118,11 @@ class OUTLINER_MT_edit_datablocks(bpy.types.Menu): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_sequencer.py b/release/scripts/ui/space_sequencer.py index 110cb74d3c5..3ae1e35aaf8 100644 --- a/release/scripts/ui/space_sequencer.py +++ b/release/scripts/ui/space_sequencer.py @@ -831,11 +831,11 @@ class SEQUENCER_PT_view(SequencerButtonsPanel_Output, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_text.py b/release/scripts/ui/space_text.py index 58f12ba51e4..df5967c9128 100644 --- a/release/scripts/ui/space_text.py +++ b/release/scripts/ui/space_text.py @@ -295,11 +295,11 @@ class TEXT_MT_toolbox(bpy.types.Menu): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_time.py b/release/scripts/ui/space_time.py index c1293e87c85..046274abc89 100644 --- a/release/scripts/ui/space_time.py +++ b/release/scripts/ui/space_time.py @@ -200,11 +200,11 @@ class TIME_MT_autokey(bpy.types.Menu): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_userpref.py b/release/scripts/ui/space_userpref.py index ff88ed4008c..79bdff8ad93 100644 --- a/release/scripts/ui/space_userpref.py +++ b/release/scripts/ui/space_userpref.py @@ -1276,11 +1276,11 @@ class WM_OT_addon_expand(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_userpref_keymap.py b/release/scripts/ui/space_userpref_keymap.py index 316e4e2be10..a78ef1be36f 100644 --- a/release/scripts/ui/space_userpref_keymap.py +++ b/release/scripts/ui/space_userpref_keymap.py @@ -787,11 +787,11 @@ class WM_OT_keyconfig_remove(bpy.types.Operator): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_view3d.py b/release/scripts/ui/space_view3d.py index eafb46b133d..162322a8720 100644 --- a/release/scripts/ui/space_view3d.py +++ b/release/scripts/ui/space_view3d.py @@ -2306,11 +2306,11 @@ class VIEW3D_PT_context_properties(bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() diff --git a/release/scripts/ui/space_view3d_toolbar.py b/release/scripts/ui/space_view3d_toolbar.py index c3280a67b7e..163e02817a4 100644 --- a/release/scripts/ui/space_view3d_toolbar.py +++ b/release/scripts/ui/space_view3d_toolbar.py @@ -1302,11 +1302,11 @@ class VIEW3D_PT_tools_particlemode(View3DPanel, bpy.types.Panel): def register(): - pass + bpy.utils.register_module(__name__) def unregister(): - pass + bpy.utils.unregister_module(__name__) if __name__ == "__main__": register() |