0020145: EDF 666 SMESH: Modifications of GEOM groups are not taken into account

allow changing shape to mesh in case of shape being group
This commit is contained in:
eap 2009-05-25 11:20:50 +00:00
parent 9a32d230ac
commit c7b8fb12f3

View File

@ -134,9 +134,11 @@ void SMESH_Mesh::ShapeToMesh(const TopoDS_Shape & aShape)
{
if(MYDEBUG) MESSAGE("SMESH_Mesh::ShapeToMesh");
if ( !aShape.IsNull() && _isShapeToMesh )
throw SALOME_Exception(LOCALIZED ("a shape to mesh has already been defined"));
if ( !aShape.IsNull() && _isShapeToMesh ) {
if ( aShape.ShapeType() != TopAbs_COMPOUND && // group contents is allowed to change
_myMeshDS->ShapeToMesh().ShapeType() != TopAbs_COMPOUND )
throw SALOME_Exception(LOCALIZED ("a shape to mesh has already been defined"));
}
// clear current data
if ( !_myMeshDS->ShapeToMesh().IsNull() )
{