From efdef0f6369ac207a2c748f01cd6e7e8ef7db3f0 Mon Sep 17 00:00:00 2001 From: Yorik van Havre Date: Tue, 26 Jun 2018 17:31:13 -0300 Subject: [PATCH] Arch: Fixed non-GUI mode bug --- src/Mod/Arch/ArchMaterial.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Mod/Arch/ArchMaterial.py b/src/Mod/Arch/ArchMaterial.py index 8f5e3326dd..ff973cee03 100644 --- a/src/Mod/Arch/ArchMaterial.py +++ b/src/Mod/Arch/ArchMaterial.py @@ -262,7 +262,8 @@ class _ArchMaterial: d["Description"] = val if d: obj.Material = d - if FreeCADGui: + if FreeCAD.GuiUp: + import FreeCADGui # not sure why this is needed, but it is... FreeCADGui.ActiveDocument.resetEdit()