#endif
createMenu(aId, aEditMenu);
+ if (!myInspectionPanel) {
+ myInspectionPanel = myWorkshop->inspectionPanel();
+ connect(myInspectionPanel->toggleViewAction(), SIGNAL(toggled(bool)),
+ this, SLOT(onWhatIs(bool)));
+ }
+ hideInternalWindows();
+
// Initialize viewer proxy if OCC viewer is already exist
ViewManagerList aOCCViewManagers;
application()->viewManagers(OCCViewer_Viewer::Type(), aOCCViewManagers);
aObjDoc->toggleViewAction()->setVisible(true);
}
- if (!myInspectionPanel) {
- myInspectionPanel = myWorkshop->inspectionPanel();
- connect(myInspectionPanel->toggleViewAction(), SIGNAL(toggled(bool)),
- this, SLOT(onWhatIs(bool)));
- }
myInspectionPanel->toggleViewAction()->setVisible(true);
myWorkshop->facesPanel()->toggleViewAction()->setVisible(true);
}
//******************************************************
-bool SHAPERGUI::deactivateModule(SUIT_Study* theStudy)
+void SHAPERGUI::hideInternalWindows()
{
- saveToolbarsConfig();
-
myProxyViewer->activateViewer(false);
setMenuShown(false);
setToolShown(false);
- myWorkshop->deactivateModule();
-
QObject* aObj = myWorkshop->objectBrowser()->parent();
QDockWidget* aObjDoc = dynamic_cast<QDockWidget*>(aObj);
if (aObjDoc) {
aObjDoc->toggleViewAction()->setVisible(false);
}
- myIsInspectionVisible = myInspectionPanel->isVisible();
myInspectionPanel->hide();
myInspectionPanel->toggleViewAction()->setVisible(false);
- myIsFacesPanelVisible = myWorkshop->facesPanel()->isVisible();
myWorkshop->facesPanel()->hide();
myWorkshop->facesPanel()->toggleViewAction()->setVisible(false);
myWorkshop->propertyPanel()->hide();
myWorkshop->propertyPanel()->toggleViewAction()->setVisible(false);
+ myWorkshop->hidePanel(myWorkshop->facesPanel());
+}
+
+
+//******************************************************
+bool SHAPERGUI::deactivateModule(SUIT_Study* theStudy)
+{
+ saveToolbarsConfig();
+ myWorkshop->deactivateModule();
+
+ myIsInspectionVisible = myInspectionPanel->isVisible();
+ myIsFacesPanelVisible = myWorkshop->facesPanel()->isVisible();
+ hideInternalWindows();
+
+
// the active operation should be stopped for the next activation.
// There should not be active operation and visualized preview.
// Abort operation should be performed before the selection's remove
mySelector = 0;
}
- myWorkshop->hidePanel(myWorkshop->facesPanel());
//myWorkshop->contextMenuMgr()->disconnectViewer();
SUIT_ResourceMgr* aResMgr = application()->resourceMgr();