- if (send != StartPointLineEdit && send != ElementsLineEdit)
- send = ElementsLineEdit;
-
- if (send == ElementsLineEdit && myEditCurrentArgument == ElementsLineEdit) {
- // hilight entered elements
- SMDS_Mesh* aMesh = 0;
- if (myMeshActor)
- aMesh = myMeshActor->GetObject()->GetMesh();
-
- if (aMesh) {
- //mySelectionMgr->clearSelected();
- //mySelectionMgr->AddIObject(myMeshActor->getIO());
- SALOME_ListIO aList;
- aList.Append(myMeshActor->getIO());
- mySelectionMgr->setSelectedObjects(aList, false);
-
- QStringList aListId = theNewText.split(" ", QString::SkipEmptyParts);
- bool bOk;
- const Handle(SALOME_InteractiveObject)& anIO = myMeshActor->getIO();
- TColStd_MapOfInteger newIndices;
- for (int i = 0; i < aListId.count(); i++) {
- long ind = aListId[ i ].toLong(&bOk);
- if (bOk) {
- const SMDS_MeshElement* e = aMesh->FindElement(ind);
- if (e) {
- // check also type of element
- bool typeMatch = (Elements1dRB->isChecked() && e->GetType() == SMDSAbs_Edge) ||
- (Elements2dRB->isChecked() && e->GetType() == SMDSAbs_Face);
- if (typeMatch)
- newIndices.Add(e->GetID());
- }
- }
- }
- mySelector->AddOrRemoveIndex(anIO, newIndices, false);
- if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))
- aViewWindow->highlight( anIO, true, true );
- }
- }
- else if (send == StartPointLineEdit &&
- myEditCurrentArgument == StartPointLineEdit) {