X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_RemoveElementsDlg.cxx;h=885fd642c5b98e6f26797df9a3fb312a421f1691;hb=4ff5bd61540272713e48de1eee75625028c32155;hp=16529726e7d9342c6f2780ce67137bcb1d26b06e;hpb=b33324fe602b1fe1158c14a866c3802df12370fa;p=modules%2Fsmesh.git diff --git a/src/SMESHGUI/SMESHGUI_RemoveElementsDlg.cxx b/src/SMESHGUI/SMESHGUI_RemoveElementsDlg.cxx index 16529726e..885fd642c 100644 --- a/src/SMESHGUI/SMESHGUI_RemoveElementsDlg.cxx +++ b/src/SMESHGUI/SMESHGUI_RemoveElementsDlg.cxx @@ -45,6 +45,7 @@ #include "SVTK_ViewWindow.h" #include "SALOME_ListIO.hxx" +#include "SalomeApp_Tools.h" #include "utilities.h" // OCCT Includes @@ -218,10 +219,6 @@ void SMESHGUI_RemoveElementsDlg::Init() connect(myEditCurrentArgument, SIGNAL(textChanged(const QString&)), SLOT(onTextChange(const QString&))); - /* Move widget on the botton right corner of main widget */ - int x, y; - mySMESHGUI->DefineDlgPosition(this, x, y); - this->move(x, y); this->show(); /* displays Dialog */ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI )) @@ -257,11 +254,16 @@ void SMESHGUI_RemoveElementsDlg::ClickOnApply() try { SMESH::SMESH_MeshEditor_var aMeshEditor = myMesh->GetMeshEditor(); aResult = aMeshEditor->RemoveElements(anArrayOfIdeces.inout()); - } catch (...) { + } catch (const SALOME::SALOME_Exception& S_ex) { + SalomeApp_Tools::QtCatchCorbaException(S_ex); + myEditCurrentArgument->clear(); + } catch (...){ + myEditCurrentArgument->clear(); } if (aResult) { myEditCurrentArgument->clear(); + mySelector->ClearIndex(); SMESH::UpdateView(); } } @@ -285,7 +287,7 @@ void SMESHGUI_RemoveElementsDlg::ClickOnOk() //================================================================================= void SMESHGUI_RemoveElementsDlg::ClickOnCancel() { - mySelectionMgr->clearSelected(); + //mySelectionMgr->clearSelected(); if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI )) aViewWindow->SetSelectionMode(ActorSelection); disconnect(mySelectionMgr, 0, this, 0);