mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-06 07:51:47 +00:00
Refresh railing preview on every gizmo edit
update_railing skipped the bmesh rebuild for WALL_MOUNTED_HANDRAIL railings because the only mesh source available at the time mutated IFC. The viewport-only preview helper that lands with the parametric gizmo work (generate_wall_mounted_handrail_preview) sidesteps IFC entirely, so the WALL_MOUNTED_HANDRAIL branch can join the FRAMELESS_PANEL path and trigger update_railing_modifier_bmesh on every property write. Gizmo drag now repaints the viewport in real time instead of waiting for Finish Editing. Generated with the assistance of an AI coding tool.
This commit is contained in:
@@ -228,11 +228,7 @@ def update_wall_offset_baseline(self: "BIMWallProperties", context: bpy.types.Co
|
||||
def update_railing(self: "BIMRailingProperties", context: bpy.types.Context) -> None:
|
||||
"""Regenerate railing mesh when property changes."""
|
||||
if self.is_editing:
|
||||
# Only FRAMELESS_PANEL can update live via bmesh.
|
||||
# WALL_MOUNTED_HANDRAIL geometry is generated from IFC representation,
|
||||
# so it only updates on "Finish Editing" to avoid modifying IFC during preview.
|
||||
if self.railing_type == "FRAMELESS_PANEL":
|
||||
_get_updater("railing", "update_railing_modifier_bmesh")(context)
|
||||
_get_updater("railing", "update_railing_modifier_bmesh")(context)
|
||||
|
||||
|
||||
def update_roof(self: "BIMRoofProperties", context: bpy.types.Context) -> None:
|
||||
|
||||
Reference in New Issue
Block a user