Salome HOME
53068: Create Mesh dialog box is frozen
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_Hypotheses.cxx
index 7d1495845630e6fbd9f600b6915d085253a04773..504607da543b8e70bdf7004f2e04a889f38568c1 100644 (file)
@@ -41,6 +41,7 @@
 #include <SUIT_ResourceMgr.h>
 #include <SUIT_Session.h>
 #include <SalomeApp_IntSpinBox.h>
+#include <SalomeApp_Tools.h>
 
 // Qt includes
 #include <QFrame>
@@ -273,13 +274,20 @@ void SMESHGUI_GenericHypothesisCreator::onDialogFinished( int result )
   bool res = result==QDialog::Accepted;
   if( res )
   {
-    SUIT_OverrideCursor wc;
-      /*QString paramValues = */storeParams();
+    try
+    {
+      SUIT_OverrideCursor wc;
+      storeParams();
       // No longer needed since NoteBook appears and "Value" OB field shows names of variable
-//       if ( !paramValues.isEmpty() ) {
-//         if ( _PTR(SObject) SHyp = SMESH::FindSObject( myHypo ))
-//           SMESH::SetValue( SHyp, paramValues );
-//       }
+      // QString paramValues = storeParams();
+      // if ( !paramValues.isEmpty() ) {
+      //   if ( _PTR(SObject) SHyp = SMESH::FindSObject( myHypo ))
+      //     SMESH::SetValue( SHyp, paramValues );
+      // }
+    }
+    catch ( const SALOME::SALOME_Exception& S_ex ) {
+      SalomeApp_Tools::QtCatchCorbaException( S_ex );
+    }
   }
 
   changeWidgets().clear();