}
aResult = (anError == SMESH::SMESH_MeshEditor::SEW_OK);
- if (toMerge && aResult)
- aMeshEditor->MergeEqualElements();
+ if (toMerge && aResult) {
+ SMESH::array_of_long_array_var aGroupsOfElementsID = new SMESH::array_of_long_array;
+ aMeshEditor->FindEqualElements(myMesh, aGroupsOfElementsID);
+ aMeshEditor->MergeEqualElements(aGroupsOfElementsID.inout());
+ }
QApplication::restoreOverrideCursor();
aNewEditor.FindCoincidentNodes( aMeshNodes, theMergeTolerance, aGroupsOfNodes );
aNewEditor.MergeNodes( aGroupsOfNodes );
// merge elements
- aNewEditor.MergeEqualElements();
+ set<const SMDS_MeshElement*> aMeshElements; // no input elements
+ SMESH_MeshEditor::TListOfListOfElementsID aGroupsOfElementsID;
+ aNewEditor.FindEqualElements(aMeshElements, aGroupsOfElementsID);
+ aNewEditor.MergeEqualElements(aGroupsOfElementsID);
}
}
}