Salome HOME
PR: synchro V7_main tag mergefrom_V6_main_28Feb13
[modules/smesh.git] / src / StdMeshers / StdMeshers_Penta_3D.cxx
index b9d46da9ef1e25d40e2b67a6f59e460a4bc6bc04..29c935a64042f4f12735af016e75e944de6bfba5 100644 (file)
@@ -1,23 +1,23 @@
-//  Copyright (C) 2007-2010  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2012  CEA/DEN, EDF R&D, OPEN CASCADE
 //
-//  Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-//  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+// Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
 //
-//  This library is free software; you can redistribute it and/or
-//  modify it under the terms of the GNU Lesser General Public
-//  License as published by the Free Software Foundation; either
-//  version 2.1 of the License.
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
 //
-//  This library is distributed in the hope that it will be useful,
-//  but WITHOUT ANY WARRANTY; without even the implied warranty of
-//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-//  Lesser General Public License for more details.
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+// Lesser General Public License for more details.
 //
-//  You should have received a copy of the GNU Lesser General Public
-//  License along with this library; if not, write to the Free Software
-//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
 //
-//  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 //
 
 //  SMESH StdMeshers_Penta_3D implementaion of SMESH idl descriptions
@@ -235,7 +235,7 @@ void StdMeshers_Penta_3D::MakeNodes()
       //
       if ( SMESH_Block::IsEdgeID (aSID)) {
         const SMDS_EdgePosition* epos =
-          static_cast<const SMDS_EdgePosition*>(aNode->GetPosition().get());
+          static_cast<const SMDS_EdgePosition*>(aNode->GetPosition());
         myBlock.ComputeParameters( epos->GetUParameter(), aS, aCoords );
       }
       else {
@@ -849,7 +849,8 @@ void StdMeshers_Penta_3D::MakeMeshOnFxy1()
   // assure that mesh on the top face will be cleaned when it is cleaned
   // on the bottom face
   SMESH_subMesh* volSM = pMesh->GetSubMesh( myTool->GetSubShape() );
-  volSM->SetEventListener( new SMESH_subMeshEventListener(true),
+  volSM->SetEventListener( new SMESH_subMeshEventListener(true, // deletable by SMESH_subMesh
+                                                          "StdMeshers_Penta_3D"),
                            SMESH_subMeshEventListenerData::MakeData( aSubMesh1 ),
                            aSubMesh0 ); // translate CLEAN event of aSubMesh0 to aSubMesh1
 }
@@ -1336,8 +1337,8 @@ void StdMeshers_Penta_3D::CheckData()
     iNb=aM.Extent();
     if (iNb!=iNbEx[i]){
       MESSAGE("StdMeshers_Penta_3D::CheckData() ");
-      myErrorStatus->myName=4; // number of subshape is not compatible
-      myErrorStatus->myComment="Wrong number of subshapes of a block";
+      myErrorStatus->myName=4; // number of sub-shape is not compatible
+      myErrorStatus->myComment="Wrong number of sub-shapes of a block";
       return;
     }
   }
@@ -1465,7 +1466,7 @@ bool StdMeshers_Penta_3D::LoadIJNodes(StdMeshers_IJNodeMap & theIJNodes,
     if(myTool->IsMedium(node))
       continue;
     const SMDS_EdgePosition* pos =
-      dynamic_cast<const SMDS_EdgePosition*>( node->GetPosition().get() );
+      dynamic_cast<const SMDS_EdgePosition*>( node->GetPosition() );
     if ( !pos ) {
       return false;
     }
@@ -1488,7 +1489,7 @@ bool StdMeshers_Penta_3D::LoadIJNodes(StdMeshers_IJNodeMap & theIJNodes,
     if(myTool->IsMedium(node))
       continue;
     const SMDS_EdgePosition* pos =
-      dynamic_cast<const SMDS_EdgePosition*>( node->GetPosition().get() );
+      dynamic_cast<const SMDS_EdgePosition*>( node->GetPosition() );
     if ( !pos ) {
       return false;
     }
@@ -1649,7 +1650,7 @@ SMESH_ComputeErrorPtr StdMeshers_SMESHBlock::GetError() const
   case 3: text = "Internal error of StdMeshers_Penta_3D"; break; 
   case 4: text = "Can't compute normalized parameters of a point inside a block"; break;
   case 5: text = "Can't compute coordinates by normalized parameters inside a block"; break;
-  case 6: text = "Can't detect block subshapes. Not a block?"; break;
+  case 6: text = "Can't detect block sub-shapes. Not a block?"; break;
   }
   if (!text.empty())
     err->myName = myErrorStatus;