Salome HOME
Enable canceling Compute
authoreap <eap@opencascade.com>
Thu, 14 Nov 2013 14:25:12 +0000 (14:25 +0000)
committereap <eap@opencascade.com>
Thu, 14 Nov 2013 14:25:12 +0000 (14:25 +0000)
src/SMESH/SMESH_Gen.cxx
src/SMESH_I/SMESH_Gen_i.cxx

index 793566ed987c44d9a27decbfa39e4cd4e229eede..c5addaf0ed7c80e89d7eede2cad378b559ecd4c9 100644 (file)
@@ -392,8 +392,6 @@ bool SMESH_Gen::Compute(SMESH_Mesh &          aMesh,
   return ret;
 }
 
   return ret;
 }
 
-
-#ifdef WITH_SMESH_CANCEL_COMPUTE
 //=============================================================================
 /*!
  * Prepare Compute a mesh
 //=============================================================================
 /*!
  * Prepare Compute a mesh
@@ -419,7 +417,6 @@ void SMESH_Gen::CancelCompute(SMESH_Mesh &          aMesh,
       _sm_current->ComputeStateEngine( SMESH_subMesh::COMPUTE_CANCELED );
     }
 }
       _sm_current->ComputeStateEngine( SMESH_subMesh::COMPUTE_CANCELED );
     }
 }
-#endif
 
 //=============================================================================
 /*!
 
 //=============================================================================
 /*!
index 32b6fecfc3269f69e250eba997bad4cad24e7829..5bcf88bda36dcc27229ed75bdc81c6624b677f26 100644 (file)
@@ -1732,9 +1732,7 @@ CORBA::Boolean SMESH_Gen_i::Compute( SMESH::SMESH_Mesh_ptr theMesh,
         myLocShape = SMESH_Mesh::PseudoShape();
       // call implementation compute
       ::SMESH_Mesh& myLocMesh = meshServant->GetImpl();
         myLocShape = SMESH_Mesh::PseudoShape();
       // call implementation compute
       ::SMESH_Mesh& myLocMesh = meshServant->GetImpl();
-#ifdef WITH_SMESH_CANCEL_COMPUTE
       myGen.PrepareCompute( myLocMesh, myLocShape);
       myGen.PrepareCompute( myLocMesh, myLocShape);
-#endif
       bool ok = myGen.Compute( myLocMesh, myLocShape);
       meshServant->CreateGroupServants(); // algos can create groups (issue 0020918)
       myLocMesh.GetMeshDS()->Modified();
       bool ok = myGen.Compute( myLocMesh, myLocShape);
       meshServant->CreateGroupServants(); // algos can create groups (issue 0020918)
       myLocMesh.GetMeshDS()->Modified();
@@ -1764,7 +1762,6 @@ CORBA::Boolean SMESH_Gen_i::Compute( SMESH::SMESH_Mesh_ptr theMesh,
 void SMESH_Gen_i::CancelCompute( SMESH::SMESH_Mesh_ptr theMesh,
                                  GEOM::GEOM_Object_ptr theShapeObject )
 {
 void SMESH_Gen_i::CancelCompute( SMESH::SMESH_Mesh_ptr theMesh,
                                  GEOM::GEOM_Object_ptr theShapeObject )
 {
-#ifdef WITH_SMESH_CANCEL_COMPUTE
   SMESH_Mesh_i* meshServant = dynamic_cast<SMESH_Mesh_i*>( GetServant( theMesh ).in() );
   ::SMESH_Mesh& myLocMesh = meshServant->GetImpl();
   TopoDS_Shape myLocShape;
   SMESH_Mesh_i* meshServant = dynamic_cast<SMESH_Mesh_i*>( GetServant( theMesh ).in() );
   ::SMESH_Mesh& myLocMesh = meshServant->GetImpl();
   TopoDS_Shape myLocShape;
@@ -1773,7 +1770,6 @@ void SMESH_Gen_i::CancelCompute( SMESH::SMESH_Mesh_ptr theMesh,
   else
     myLocShape = SMESH_Mesh::PseudoShape();
   myGen.CancelCompute( myLocMesh, myLocShape);
   else
     myLocShape = SMESH_Mesh::PseudoShape();
   myGen.CancelCompute( myLocMesh, myLocShape);
-#endif
 }
 
 //=============================================================================
 }
 
 //=============================================================================