Salome HOME
bos #17015 [CEA 17008] Body fitting with Viscous Layers for CFD meshing
[modules/smesh.git] / src / SMESH / SMESH_MeshEditor.cxx
index 395be58ac0ec4eddc45d84c06c35573b0bd66708..2fde91d6c5f641d10e7fde0ec7946cce52a448f2 100644 (file)
@@ -7279,6 +7279,7 @@ void SMESH_MeshEditor::MergeNodes (TListOfListOfNodes & theGroupsOfNodes,
   {
     const SMDS_MeshElement* elem = *eIt;
     SMESHDS_SubMesh*          sm = mesh->MeshElements( elem->getshapeId() );
+    bool                 marked = elem->isMarked();
 
     bool keepElem = applyMerge( elem, newElemDefs, nodeNodeMap, /*noHoles=*/false );
     if ( !keepElem )
@@ -7315,6 +7316,8 @@ void SMESH_MeshEditor::MergeNodes (TListOfListOfNodes & theGroupsOfNodes,
           sm->AddElement( newElem );
         if ( elem != newElem )
           ReplaceElemInGroups( elem, newElem, mesh );
+        if ( marked && newElem )
+          newElem->setIsMarked( true );
       }
     }
   }