mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-20 06:58:56 +00:00
Revert "Fix segment object parenting and add Claude Code to .gitignore"
This reverts commit e1bf717af5.
This commit is contained in:
@@ -115,8 +115,3 @@ dev_environment.bat
|
|||||||
|
|
||||||
src/ifcopenshell-python/ifcopenshell/express/*.exp
|
src/ifcopenshell-python/ifcopenshell/express/*.exp
|
||||||
src/ifcopenshell-python/ifcopenshell/express/*.exp.cache.dat
|
src/ifcopenshell-python/ifcopenshell/express/*.exp.cache.dat
|
||||||
|
|
||||||
# Claude Code
|
|
||||||
.claude/
|
|
||||||
.mcp.json
|
|
||||||
CLAUDE.md
|
|
||||||
|
|||||||
@@ -571,7 +571,6 @@ class Alignment:
|
|||||||
|
|
||||||
mapped_segments = ifcopenshell.api.alignment.get_mapped_segments(segment)
|
mapped_segments = ifcopenshell.api.alignment.get_mapped_segments(segment)
|
||||||
tool.Loader.load_settings()
|
tool.Loader.load_settings()
|
||||||
obj = None
|
|
||||||
for curve_segment in mapped_segments:
|
for curve_segment in mapped_segments:
|
||||||
if curve_segment is not None:
|
if curve_segment is not None:
|
||||||
geometry = tool.Loader.create_generic_shape(curve_segment)
|
geometry = tool.Loader.create_generic_shape(curve_segment)
|
||||||
@@ -579,16 +578,7 @@ class Alignment:
|
|||||||
mesh = ifc_importer.create_mesh(curve_segment, geometry)
|
mesh = ifc_importer.create_mesh(curve_segment, geometry)
|
||||||
obj = bpy.data.objects.new(tool.Loader.get_name(curve_segment), mesh)
|
obj = bpy.data.objects.new(tool.Loader.get_name(curve_segment), mesh)
|
||||||
tool.Ifc.link(curve_segment, obj)
|
tool.Ifc.link(curve_segment, obj)
|
||||||
|
tool.Collector.assign(obj)
|
||||||
# Parent to layout object for proper hierarchy
|
|
||||||
if parent_obj:
|
|
||||||
obj.parent = parent_obj
|
|
||||||
|
|
||||||
# Assign to same collection as parent (avoid "Unsorted")
|
|
||||||
if parent_obj and parent_obj.users_collection:
|
|
||||||
parent_obj.users_collection[0].objects.link(obj)
|
|
||||||
else:
|
|
||||||
tool.Collector.assign(obj)
|
|
||||||
return obj
|
return obj
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
|
|||||||
Reference in New Issue
Block a user