From 90044b128369c19ed8f53ee2c84d2c71e604e317 Mon Sep 17 00:00:00 2001 From: 0penBrain Date: Fri, 12 Jul 2019 23:54:32 +0200 Subject: [PATCH] Add basic ability that PartDesign doesn't switch to Task panel when activated => Add a 'SwitchToTask' boolean parameter to Mod/PartDesign and set to 'false' to prevent switching --- src/Mod/PartDesign/Gui/Workbench.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Mod/PartDesign/Gui/Workbench.cpp b/src/Mod/PartDesign/Gui/Workbench.cpp index e2b503f457..bf037e4990 100644 --- a/src/Mod/PartDesign/Gui/Workbench.cpp +++ b/src/Mod/PartDesign/Gui/Workbench.cpp @@ -430,7 +430,8 @@ void Workbench::activated() _switchToDocument(App::GetApplication().getActiveDocument()); addTaskWatcher(Watcher); - Gui::Control().showTaskView(); + if(App::GetApplication().GetUserParameter().GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/PartDesign")->GetBool("SwitchToTask", true)) + Gui::Control().showTaskView(); // Let us be notified when a document is activated, so that we can update the ActivePartObject Gui::Application::Instance->signalActiveDocument.connect(boost::bind(&Workbench::slotActiveDocument, this, _1));