Arch: Fixed bug that builds a structure on top of another structure
This commit is contained in:
parent
1e860356e7
commit
dceed60c98
|
@ -352,6 +352,7 @@ class _CommandStructure:
|
|||
self.continueCmd = False
|
||||
sel = FreeCADGui.Selection.getSelection()
|
||||
if sel:
|
||||
if Draft.getType(sel[0]) != "Structure":
|
||||
# direct creation
|
||||
FreeCAD.ActiveDocument.openTransaction(str(translate("Arch","Create Structure")))
|
||||
FreeCADGui.doCommand("import Arch")
|
||||
|
@ -366,7 +367,8 @@ class _CommandStructure:
|
|||
FreeCADGui.doCommand("Arch.makeStructure(FreeCAD.ActiveDocument." + obj.Name + ")")
|
||||
FreeCAD.ActiveDocument.commitTransaction()
|
||||
FreeCAD.ActiveDocument.recompute()
|
||||
else:
|
||||
return
|
||||
|
||||
# interactive mode
|
||||
if hasattr(FreeCAD,"DraftWorkingPlane"):
|
||||
FreeCAD.DraftWorkingPlane.setup()
|
||||
|
|
Loading…
Reference in New Issue
Block a user