mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
Small presentation layers UI fixes
This commit is contained in:
@@ -40,6 +40,8 @@ class LayersData:
|
||||
|
||||
@classmethod
|
||||
def active_layers(cls):
|
||||
if not bpy.context.active_object:
|
||||
return []
|
||||
data = bpy.context.active_object.data
|
||||
if not data:
|
||||
return []
|
||||
|
||||
@@ -137,6 +137,7 @@ class RemovePresentationLayer(bpy.types.Operator):
|
||||
class AssignPresentationLayer(bpy.types.Operator):
|
||||
bl_idname = "bim.assign_presentation_layer"
|
||||
bl_label = "Assign Presentation Layer"
|
||||
bl_description = "Assign presentation layer to the active representation of the active object"
|
||||
bl_options = {"REGISTER", "UNDO"}
|
||||
item: bpy.props.StringProperty()
|
||||
layer: bpy.props.IntProperty()
|
||||
@@ -158,6 +159,7 @@ class AssignPresentationLayer(bpy.types.Operator):
|
||||
class UnassignPresentationLayer(bpy.types.Operator):
|
||||
bl_idname = "bim.unassign_presentation_layer"
|
||||
bl_label = "Unassign Presentation Layer"
|
||||
bl_description = "Unassign presentation layer from the active representation of the active object"
|
||||
bl_options = {"REGISTER", "UNDO"}
|
||||
item: bpy.props.StringProperty()
|
||||
layer: bpy.props.IntProperty()
|
||||
|
||||
Reference in New Issue
Block a user