From: vsv Date: Mon, 27 Aug 2018 14:34:14 +0000 (+0300) Subject: Issue #2582: Show/Hide inspection panel on activate/deactivate SHAPER module. X-Git-Tag: SHAPER_V9_1_0RC1~18 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=ee9dac2e71e9f488bf3a092ef351a7cf64b94140;p=modules%2Fshaper.git Issue #2582: Show/Hide inspection panel on activate/deactivate SHAPER module. --- diff --git a/src/SHAPERGUI/SHAPERGUI.cpp b/src/SHAPERGUI/SHAPERGUI.cpp index ad2809535..9fe4223b1 100644 --- a/src/SHAPERGUI/SHAPERGUI.cpp +++ b/src/SHAPERGUI/SHAPERGUI.cpp @@ -207,6 +207,13 @@ bool SHAPERGUI::activateModule(SUIT_Study* theStudy) desktop()->tabifyDockWidget(aObjDoc, myWorkshop->propertyPanel()); } + DockWidget* aInspection = myWorkshop->inspectionPanel(); + if (aInspection) { + QAction* aViewAct = aInspection->toggleViewAction(); + aViewAct->setEnabled(true); + aInspection->setVisible(true); + } + if (!mySelector) { ViewManagerList OCCViewManagers; application()->viewManagers(OCCViewer_Viewer::Type(), OCCViewManagers); @@ -306,6 +313,12 @@ bool SHAPERGUI::deactivateModule(SUIT_Study* theStudy) QAction* aViewAct = aObjDoc->toggleViewAction(); aViewAct->setEnabled(false); } + DockWidget* aInspection = myWorkshop->inspectionPanel(); + if (aInspection) { + aInspection->setVisible(false); + QAction* aViewAct = aInspection->toggleViewAction(); + aViewAct->setEnabled(false); + } // the active operation should be stopped for the next activation. // There should not be active operation and visualized preview.