mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-22 07:28:38 +00:00
Fix #4722. Things like type elements are not allowed to have openings applied to them.
This commit is contained in:
@@ -77,6 +77,10 @@ class AddOpening(bpy.types.Operator, tool.Ifc.Operator):
|
|||||||
self.report({"INFO"}, "You can't add an opening to another opening.")
|
self.report({"INFO"}, "You can't add an opening to another opening.")
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
if not hasattr(element1, "HasOpenings"):
|
||||||
|
self.report({"INFO"}, f"An {element1.is_a()} is not allowed to have an opening.")
|
||||||
|
continue
|
||||||
|
|
||||||
if tool.Ifc.is_moved(obj1):
|
if tool.Ifc.is_moved(obj1):
|
||||||
blenderbim.core.geometry.edit_object_placement(tool.Ifc, tool.Geometry, tool.Surveyor, obj=obj1)
|
blenderbim.core.geometry.edit_object_placement(tool.Ifc, tool.Geometry, tool.Surveyor, obj=obj1)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user