]> SALOME platform Git repositories - modules/shaper.git/blobdiff - src/XGUI/XGUI_Workshop.cpp
Salome HOME
Merge branch 'Pre_2.8.0_development'
[modules/shaper.git] / src / XGUI / XGUI_Workshop.cpp
index ec7da2e25e629aef667d9df4ca2785edef7b3b87..b08c24cd73015b39db537c8596c3b772a710f8cc 100755 (executable)
@@ -508,7 +508,7 @@ void XGUI_Workshop::onAcceptActionClicked()
                                                     (anOperationMgr->currentOperation());
     if (aFOperation) {
       //if (errorMgr()->canProcessClick(anAction, aFOperation->feature()))
-      myOperationMgr->onCommitOperation();
+      myOperationMgr->commitOperation();
     }
   }
 }
@@ -776,12 +776,6 @@ void XGUI_Workshop::saveDocument(const QString& theName, std::list<std::string>&
   QApplication::restoreOverrideCursor();
 }
 
-//******************************************************
-bool XGUI_Workshop::abortAllOperations()
-{
-  return myOperationMgr->abortAllOperations();
-}
-
 //******************************************************
 void XGUI_Workshop::operationStarted(ModuleBase_Operation* theOperation)
 {
@@ -797,7 +791,7 @@ void XGUI_Workshop::operationStarted(ModuleBase_Operation* theOperation)
 //******************************************************
 void XGUI_Workshop::onOpen()
 {
-  if(!abortAllOperations())
+  if(!myOperationMgr->abortAllOperations())
     return;
   //save current file before close if modified
   SessionPtr aSession = ModelAPI_Session::get();
@@ -927,7 +921,7 @@ void XGUI_Workshop::onTrihedronVisibilityChanged(bool theState)
 //******************************************************
 bool XGUI_Workshop::onSave()
 {
-  if(!abortAllOperations())
+  if(!myOperationMgr->abortAllOperations(XGUI_OperationMgr::XGUI_InformationMessage))
     return false;
   if (myCurrentDir.isEmpty()) {
     return onSaveAs();
@@ -944,7 +938,7 @@ bool XGUI_Workshop::onSave()
 //******************************************************
 bool XGUI_Workshop::onSaveAs()
 {
-  if(!abortAllOperations())
+  if(!myOperationMgr->abortAllOperations(XGUI_OperationMgr::XGUI_InformationMessage))
     return false;
   QFileDialog dialog(desktop());
   dialog.setWindowTitle(tr("Select directory to save files..."));
@@ -1472,7 +1466,7 @@ void XGUI_Workshop::deleteObjects()
   }
 
   QObjectPtrList anObjects = mySelector->selection()->selectedObjects();
-  if (!abortAllOperations())
+  if (!myOperationMgr->abortAllOperations())
     return;
 
   bool hasResult = false;
@@ -1539,7 +1533,7 @@ void addRefsToFeature(const FeaturePtr& theFeature,
 //**************************************************************
 void XGUI_Workshop::cleanHistory()
 {
-  if (!abortAllOperations())
+  if (!myOperationMgr->abortAllOperations())
     return;
 
   QObjectPtrList anObjects = mySelector->selection()->selectedObjects();
@@ -1665,7 +1659,7 @@ void XGUI_Workshop::cleanHistory()
 //**************************************************************
 void XGUI_Workshop::moveObjects()
 {
-  if (!abortAllOperations())
+  if (!myOperationMgr->abortAllOperations())
     return;
 
   SessionPtr aMgr = ModelAPI_Session::get();
@@ -1906,7 +1900,7 @@ void XGUI_Workshop::changeColor(const QObjectPtrList& theObjects)
   if (aColor.size() != 3)
     return;
 
-  if (!abortAllOperations())
+  if (!myOperationMgr->abortAllOperations())
   return;
   // 2. show the dialog to change the value
   XGUI_ColorDialog* aDlg = new XGUI_ColorDialog(desktop());
@@ -1996,7 +1990,7 @@ void XGUI_Workshop::changeDeflection(const QObjectPtrList& theObjects)
   if (aDeflection < 0)
     return;
 
-  if (!abortAllOperations())
+  if (!myOperationMgr->abortAllOperations())
   return;
   // 2. show the dialog to change the value
   XGUI_DeflectionDialog* aDlg = new XGUI_DeflectionDialog(desktop());