X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_NodesDlg.cxx;h=e4010b893cc37f4c151bd720da0bb934a2be36bb;hp=d82ec9c1d8aaaae1d3627a0783f13faa9543ba81;hb=88b3dbe23b236bd1746405155ae33a76aaf59ecd;hpb=cb4e582b0cbbcf1864292d59535033ad724e46f2 diff --git a/src/SMESHGUI/SMESHGUI_NodesDlg.cxx b/src/SMESHGUI/SMESHGUI_NodesDlg.cxx index d82ec9c1d..e4010b893 100644 --- a/src/SMESHGUI/SMESHGUI_NodesDlg.cxx +++ b/src/SMESHGUI/SMESHGUI_NodesDlg.cxx @@ -370,7 +370,7 @@ void SMESHGUI_NodesDlg::Init() /* signals and slots connections */ connect( buttonOk, SIGNAL( clicked() ), this, SLOT( ClickOnOk() ) ); - connect( buttonCancel, SIGNAL( clicked() ), this, SLOT( ClickOnCancel() ) ); + connect( buttonCancel, SIGNAL( clicked() ), this, SLOT( reject() ) ); connect( buttonApply, SIGNAL( clicked() ), this, SLOT( ClickOnApply() ) ); connect( buttonHelp, SIGNAL( clicked() ), this, SLOT( ClickOnHelp() ) ); @@ -381,8 +381,8 @@ void SMESHGUI_NodesDlg::Init() connect( mySelectionMgr, SIGNAL( currentSelectionChanged() ), SLOT( SelectionIntoArgument() ) ); connect( mySMESHGUI, SIGNAL( SignalDeactivateActiveDialog() ), SLOT( DeactivateActiveDialog() ) ); /* to close dialog if study frame change */ - connect( mySMESHGUI, SIGNAL( SignalStudyFrameChanged() ), SLOT( ClickOnCancel() ) ); - connect(mySMESHGUI, SIGNAL(SignalCloseAllDialogs()), SLOT(ClickOnCancel())); + connect( mySMESHGUI, SIGNAL( SignalStudyFrameChanged() ), SLOT( reject() ) ); + connect(mySMESHGUI, SIGNAL(SignalCloseAllDialogs()), SLOT(reject())); // set selection mode SMESH::SetPointRepresentation( true ); @@ -414,7 +414,7 @@ void SMESHGUI_NodesDlg::ValueChangedInSpinBox( double newValue ) void SMESHGUI_NodesDlg::ClickOnOk() { if ( ClickOnApply() ) - ClickOnCancel(); + reject(); } //================================================================================= @@ -539,10 +539,10 @@ bool SMESHGUI_NodesDlg::ClickOnApply() } //================================================================================= -// function : ClickOnCancel() +// function : reject() // purpose : //================================================================================= -void SMESHGUI_NodesDlg::ClickOnCancel() +void SMESHGUI_NodesDlg::reject() { disconnect( mySelectionMgr, 0, this, 0 ); if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ) ) @@ -552,7 +552,7 @@ void SMESHGUI_NodesDlg::ClickOnCancel() SMESH::SetPointRepresentation( false ); mySMESHGUI->ResetState(); - reject(); + QDialog::reject(); } //================================================================================= @@ -638,25 +638,6 @@ void SMESHGUI_NodesDlg::SelectionIntoArgument() } } -//================================================================================= -// function : closeEvent() -// purpose : -//================================================================================= -void SMESHGUI_NodesDlg::closeEvent( QCloseEvent* ) -{ - this->ClickOnCancel(); /* same than click on cancel button */ -} - -//================================================================================= -// function : hideEvent() -// purpose : caused by ESC key -//================================================================================= -void SMESHGUI_NodesDlg::hideEvent( QHideEvent* ) -{ - if ( !isMinimized() ) - ClickOnCancel(); -} - //================================================================================= // function : enterEvent() // purpose : to reactivate this dialog box when mouse enter onto the window