Fix bug where selecting element / element type without representation wasn't updating bim tools active type

This commit is contained in:
Andrej730
2025-02-10 14:20:46 +05:00
parent d8a250f153
commit b2d66bbb89
+4 -4
View File
@@ -113,10 +113,6 @@ def update_bim_tool_props():
if not element:
return
representation = ifcopenshell.util.representation.get_representation(element, "Model", "Body", "MODEL_VIEW")
if not representation:
return
props = tool.Model.get_model_props()
aprops = tool.Drawing.get_annotation_props()
TOOLS_TO_CLASSES_MAP = tool.Blender.get_tools_to_classes_map()
@@ -140,6 +136,10 @@ def update_bim_tool_props():
if is_annotation_tool:
return
representation = ifcopenshell.util.representation.get_representation(element, "Model", "Body", "MODEL_VIEW")
if not representation:
return
extrusion = tool.Model.get_extrusion(representation)
if not extrusion:
return