Salome HOME
22355: EDF SMESH: New 1D hypothesis "Adaptive"
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_MultiEditDlg.cxx
index ee4e206b2eda23c6b4153fcc0a37023fd787c59a..1384b9376713c74804b1a53d647ead8b91ba3c60 100755 (executable)
@@ -1212,7 +1212,7 @@ bool SMESHGUI_CuttingOfQuadsDlg::process (SMESH::SMESH_MeshEditor_ptr theEditor,
     {
       if ( hasObj )
         return theEditor->QuadTo4Tri( obj ), true;
-      SMESH::SMESH_IDSource_var elems = theEditor->MakeIDSource( theIds, SMESH::FACE );
+      SMESH::SMESH_IDSource_wrap elems = theEditor->MakeIDSource( theIds, SMESH::FACE );
       theEditor->QuadTo4Tri( elems );
       return true;
     }
@@ -1466,9 +1466,11 @@ bool SMESHGUI_CuttingIntoTetraDlg::process (SMESH::SMESH_MeshEditor_ptr theEdito
                                             const SMESH::long_array&    theIds,
                                             SMESH::SMESH_IDSource_ptr   theObj)
 {
-  SMESH::SMESH_IDSource_var obj = theObj;
+  SMESH::SMESH_IDSource_wrap obj = theObj;
   if ( CORBA::is_nil( obj ))
     obj = theEditor->MakeIDSource( theIds, myEntityType ? SMESH::VOLUME : SMESH::FACE );
+  else
+    obj->Register();
   try {
     theEditor->SplitVolumesIntoTetra( obj, myGroupChoice->checkedId()+1 );
   }
@@ -1476,5 +1478,8 @@ bool SMESHGUI_CuttingIntoTetraDlg::process (SMESH::SMESH_MeshEditor_ptr theEdito
     SalomeApp_Tools::QtCatchCorbaException( S_ex );
     return false;
   }
+  catch(...) {
+    return false;
+  }
   return true;
 }