diff --git a/addon/__init__.py b/addon/__init__.py index cdc840a..cd8ca2b 100644 --- a/addon/__init__.py +++ b/addon/__init__.py @@ -46,7 +46,11 @@ classes = [WM_MT_splash, OT_SelectTemplatePopup, CustomTemplatesPreferences] +original_splash = None; + def register(): + global original_splash + original_splash = bpy.types.WM_MT_splash; for c in classes: bpy.utils.register_class(c) bpy.types.TOPBAR_MT_file_new.append(draw_file_new_templates) @@ -55,6 +59,7 @@ def register(): def unregister(): for c in reversed(classes): bpy.utils.unregister_class(c) + bpy.utils.register_class(original_splash) bpy.types.TOPBAR_MT_file_new.remove(draw_file_new_templates) bpy.types.TOPBAR_MT_file_defaults.remove(draw_file_default_operators)