Salome HOME
Join modifications from branch OCC_development_for_3_2_0a2
[modules/smesh.git] / src / SMESH / SMESH_Hypothesis.cxx
index 0107c3e36dccb22247f68b2cfb0f84ff5f13d238..268581791170f4134cbd12309f7dfe2118f5bb2d 100644 (file)
@@ -72,13 +72,14 @@ SMESH_Hypothesis::~SMESH_Hypothesis()
 
 int SMESH_Hypothesis::GetDim() const
 {
 
 int SMESH_Hypothesis::GetDim() const
 {
-  int dim = -1;
+  int dim = 0;
   switch (_type)
     {
     case ALGO_1D: dim = 1; break;
     case ALGO_2D: dim = 2; break;
     case ALGO_3D: dim = 3; break;
   switch (_type)
     {
     case ALGO_1D: dim = 1; break;
     case ALGO_2D: dim = 2; break;
     case ALGO_3D: dim = 3; break;
-    case PARAM_ALGO: dim = _param_algo_dim; break;
+    case PARAM_ALGO:
+      dim = ( _param_algo_dim < 0 ) ? -_param_algo_dim : _param_algo_dim; break;
     }
   return dim;
 }
     }
   return dim;
 }
@@ -124,14 +125,15 @@ void SMESH_Hypothesis::NotifySubMeshesHypothesisModification()
        itm++)
     {
       SMESH_Mesh* mesh = (*itm).second;
        itm++)
     {
       SMESH_Mesh* mesh = (*itm).second;
-      const list<SMESH_subMesh*>& subMeshes =
-        mesh->GetSubMeshUsingHypothesis(this);
+      mesh->NotifySubMeshesHypothesisModification( this );
+//       const list<SMESH_subMesh*>& subMeshes =
+//      mesh->GetSubMeshUsingHypothesis(this);
 
 
-      //for all subMeshes using hypothesis
+//       //for all subMeshes using hypothesis
        
        
-      list<SMESH_subMesh*>::const_iterator its;
-      for (its = subMeshes.begin(); its != subMeshes.end(); its++)
-       (*its)->ComputeStateEngine(SMESH_subMesh::MODIF_HYP);
+//       list<SMESH_subMesh*>::const_iterator its;
+//       for (its = subMeshes.begin(); its != subMeshes.end(); its++)
+//     (*its)->ComputeStateEngine(SMESH_subMesh::MODIF_HYP);
     }
 }
 
     }
 }