Salome HOME
Correction tab logic.
[modules/shaper.git] / src / XGUI / XGUI_Workshop.cpp
index 948f258fa11229f445545749dbf8f7c141fe6911..60fe451c633c6b168decae34a3bbc01adfe89891 100755 (executable)
@@ -166,6 +166,7 @@ XGUI_Workshop::XGUI_Workshop(XGUI_SalomeConnector* theConnector)
 
 #ifndef HAVE_SALOME
   connect(myMainWindow, SIGNAL(exitKeySequence()), SLOT(onExit()));
+  onTrihedronVisibilityChanged(true);
 #endif
 
   connect(this, SIGNAL(errorOccurred(const QString&)), myErrorDlg, SLOT(addError(const QString&)));
@@ -1130,12 +1131,16 @@ void XGUI_Workshop::onContextMenuCommand(const QString& theId, bool isChecked)
     moveObjects();
   else if (theId == "COLOR_CMD")
     changeColor(aObjects);
-  else if (theId == "SHOW_CMD")
+  else if (theId == "SHOW_CMD") {
     showObjects(aObjects, true);
+    mySelector->updateSelectionBy(ModuleBase_ISelection::Browser);
+  }
   else if (theId == "HIDE_CMD")
     showObjects(aObjects, false);
-  else if (theId == "SHOW_ONLY_CMD")
+  else if (theId == "SHOW_ONLY_CMD") {
     showOnlyObjects(aObjects);
+    mySelector->updateSelectionBy(ModuleBase_ISelection::Browser);
+  }
   else if (theId == "SHADING_CMD")
     setDisplayMode(aObjects, XGUI_Displayer::Shading);
   else if (theId == "WIREFRAME_CMD")
@@ -1353,9 +1358,6 @@ bool XGUI_Workshop::deleteFeatures(const QObjectPtrList& theList,
     if (!anObjectGroups.contains(aGroupName.c_str()))
       continue;
 
-    if (!myModule->canApplyAction(aObj, anActionId))
-      continue;
-
     FeaturePtr aFeature = ModelAPI_Feature::feature(aObj);
     if (aFeature) {
       /*// TODO: to learn the workshop to delegate the Part object deletion to the PartSet module