X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_RemoveElementsDlg.cxx;h=31a46b557fb3799dc46b4ec7c41eeb037f1e6b1e;hp=1decdeff61f3cad222877bc3958701877badba6f;hb=eda06d81d6e5947fa63a55261bab6c407ee02ed4;hpb=193c49c87753b6ccabb2b5e6dc935aa480d2d43e diff --git a/src/SMESHGUI/SMESHGUI_RemoveElementsDlg.cxx b/src/SMESHGUI/SMESHGUI_RemoveElementsDlg.cxx index 1decdeff6..31a46b557 100644 --- a/src/SMESHGUI/SMESHGUI_RemoveElementsDlg.cxx +++ b/src/SMESHGUI/SMESHGUI_RemoveElementsDlg.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2015 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2016 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 @@ -42,6 +42,7 @@ #include #include #include +#include #include #include @@ -80,8 +81,8 @@ SMESHGUI_RemoveElementsDlg ::SMESHGUI_RemoveElementsDlg(SMESHGUI* theModule) : QDialog(SMESH::GetDesktop(theModule)), - mySelector(SMESH::GetViewWindow(theModule)->GetSelector()), mySelectionMgr(SMESH::GetSelectionMgr(theModule)), + mySelector(SMESH::GetViewWindow(theModule)->GetSelector()), mySMESHGUI(theModule), myBusy(false), myFilterDlg(0) @@ -225,7 +226,10 @@ void SMESHGUI_RemoveElementsDlg::ClickOnApply() if (mySMESHGUI->isActiveStudyLocked()) return; - if (myNbOkElements) { + if (myNbOkElements) + { + SUIT_OverrideCursor wc; + QStringList aListId = myEditCurrentArgument->text().split(" ", QString::SkipEmptyParts); SMESH::long_array_var anArrayOfIdeces = new SMESH::long_array; anArrayOfIdeces->length(aListId.count()); @@ -233,7 +237,8 @@ void SMESHGUI_RemoveElementsDlg::ClickOnApply() anArrayOfIdeces[i] = aListId[ i ].toInt(); bool aResult = false; - try { + try + { SMESH::SMESH_MeshEditor_var aMeshEditor = myMesh->GetMeshEditor(); aResult = aMeshEditor->RemoveElements(anArrayOfIdeces.in()); @@ -242,15 +247,13 @@ void SMESHGUI_RemoveElementsDlg::ClickOnApply() } catch (const SALOME::SALOME_Exception& S_ex) { SalomeApp_Tools::QtCatchCorbaException(S_ex); - myEditCurrentArgument->clear(); - } catch (...){ - myEditCurrentArgument->clear(); + } catch (...) { } + myEditCurrentArgument->clear(); if (aResult) { - myEditCurrentArgument->clear(); mySelector->ClearIndex(); - SMESH::UpdateView(); + SMESH::UpdateView( /*withChildrenOfSelected=*/true ); SMESHGUI::Modified(); } } @@ -340,7 +343,7 @@ void SMESHGUI_RemoveElementsDlg::onTextChange(const QString& theNewText) myNbOkElements = 0; - // hilight entered elements + // highlight entered elements if(myActor){ if(SMDS_Mesh* aMesh = myActor->GetObject()->GetMesh()){ Handle(SALOME_InteractiveObject) anIO = myActor->getIO(); @@ -377,7 +380,7 @@ void SMESHGUI_RemoveElementsDlg::onTextChange(const QString& theNewText) void SMESHGUI_RemoveElementsDlg::SelectionIntoArgument() { if (myBusy) return; // busy - if (myFilterDlg && myFilterDlg->isVisible()) return; // filter digl active + if (myFilterDlg && myFilterDlg->isVisible()) return; // filter dlg active if (!GroupButtons->isEnabled()) return; // inactive // clear