From 34b2baeeea28d85fef84d37297491e5befe2a729 Mon Sep 17 00:00:00 2001 From: Sergo Date: Sun, 19 Mar 2017 13:44:24 -0400 Subject: [PATCH] issue #2808 --- src/Mod/PartDesign/Gui/Command.cpp | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/src/Mod/PartDesign/Gui/Command.cpp b/src/Mod/PartDesign/Gui/Command.cpp index f3c7d3176d..a36619ef4d 100644 --- a/src/Mod/PartDesign/Gui/Command.cpp +++ b/src/Mod/PartDesign/Gui/Command.cpp @@ -1905,13 +1905,15 @@ CmdPartDesignMultiTransform::CmdPartDesignMultiTransform() void CmdPartDesignMultiTransform::activated(int iMsg) { Q_UNUSED(iMsg); - App::Document *doc = getDocument(); - PartDesign::Body *pcActiveBody = PartDesignGui::getBody( - /*messageIfNot = */ PartDesignGui::assureModernWorkflow(doc)); + // No PartDesign feature without Body past FreeCAD 0.16 + App::Document *doc = getDocument(); + if (!PartDesignGui::assureModernWorkflow(doc)) + return; - // No PartDesign feature without Body past FreeCAD 0.16 - if (!pcActiveBody && PartDesignGui::isModernWorkflow(doc)) - return; + PartDesign::Body *pcActiveBody = PartDesignGui::getBody(true); + + if (!pcActiveBody) + return; std::vector features;