Initial Commit

This commit is contained in:
Yusarina
2024-06-12 03:37:46 +01:00
parent c27fe30acd
commit 0f7c46b720
8 changed files with 128 additions and 0 deletions
+23
View File
@@ -0,0 +1,23 @@
if "bpy" not in locals():
import bpy
from . import panel, quick_access, optimization
else:
import importlib
# Reload the modules to reflect changes during development
importlib.reload(panel)
importlib.reload(quick_access)
importlib.reload(optimization)
def register():
print("UI register called")
from ..core.register import iter_classes_to_register
# Iterate over the classes to register and register them
for cls in iter_classes_to_register():
bpy.utils.register_class(cls)
def unregister():
print("UI unregister called")
from ..core.register import iter_classes_to_register
# Iterate over the classes to unregister in reverse order and unregister them
for cls in reversed(list(iter_classes_to_register())):
bpy.utils.unregister_class(cls)
+16
View File
@@ -0,0 +1,16 @@
import bpy
from ..core.register import register_wrap
@register_wrap
class AvatarToolkitOptimizationPanel(bpy.types.Panel):
bl_label = "Optimization"
bl_idname = "OBJECT_PT_avatar_toolkit_optimization"
bl_space_type = 'VIEW_3D'
bl_region_type = 'UI'
bl_category = "Avatar Toolkit"
bl_parent_id = "OBJECT_PT_avatar_toolkit"
def draw(self, context):
layout = self.layout
layout.label(text="Optimization Options")
# Add optimization options here
+15
View File
@@ -0,0 +1,15 @@
import bpy
from ..core.register import register_wrap
@register_wrap
class AvatarToolkitPanel(bpy.types.Panel):
bl_label = "Avatar Toolkit"
bl_idname = "OBJECT_PT_avatar_toolkit"
bl_space_type = 'VIEW_3D'
bl_region_type = 'UI'
bl_category = "Avatar Toolkit"
def draw(self, context):
layout = self.layout
layout.label(text="Welcome to Avatar Toolkit!")
print("Avatar Toolkit Panel is being drawn")
+16
View File
@@ -0,0 +1,16 @@
import bpy
from ..core.register import register_wrap
@register_wrap
class AvatarToolkitQuickAccessPanel(bpy.types.Panel):
bl_label = "Quick Access"
bl_idname = "OBJECT_PT_avatar_toolkit_quick_access"
bl_space_type = 'VIEW_3D'
bl_region_type = 'UI'
bl_category = "Avatar Toolkit"
bl_parent_id = "OBJECT_PT_avatar_toolkit"
def draw(self, context):
layout = self.layout
layout.label(text="Quick Access Options")
# Add quick access options here