FEM: Add command only when GUI is up

Signed-off-by: Przemo Firszt <przemo@firszt.eu>
This commit is contained in:
Przemo Firszt 2015-07-28 17:02:16 +01:00 committed by Yorik van Havre
parent 1de29d0ffa
commit 461e506c41

View File

@ -265,4 +265,5 @@ class _MechanicalMaterialTaskPanel:
self.add_mat_dir(custom_mat_dir, ":/icons/user.svg")
FreeCADGui.addCommand('Fem_MechanicalMaterial', _CommandMechanicalMaterial())
if FreeCAD.GuiUp:
FreeCADGui.addCommand('Fem_MechanicalMaterial', _CommandMechanicalMaterial())