mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-12 14:33:28 +00:00
Adding openings now detects if you've selected the filling object instead
This commit is contained in:
@@ -3601,7 +3601,10 @@ class AddOpening(bpy.types.Operator):
|
|||||||
bl_label = 'Add Opening'
|
bl_label = 'Add Opening'
|
||||||
|
|
||||||
def execute(self, context):
|
def execute(self, context):
|
||||||
opening = context.active_object
|
if context.active_object.children and 'IfcOpeningElement/' in context.active_object.children[0].name:
|
||||||
|
opening = context.active_object.children[0]
|
||||||
|
else:
|
||||||
|
opening = context.active_object
|
||||||
if context.selected_objects[0] != context.active_object:
|
if context.selected_objects[0] != context.active_object:
|
||||||
obj = context.selected_objects[0]
|
obj = context.selected_objects[0]
|
||||||
else:
|
else:
|
||||||
|
|||||||
Reference in New Issue
Block a user