X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_MoveNodesDlg.cxx;h=aaeaa44815b07a424d19e55d0442a135ae7d3814;hb=d3b48c6524bfc64b2b70575cef0f4e11fd98e8b5;hp=e4bbc8bed97de1220517747ca3cbf533916831d6;hpb=ddd20dd94358856385f639219bbdfbd1e14239d7;p=modules%2Fsmesh.git diff --git a/src/SMESHGUI/SMESHGUI_MoveNodesDlg.cxx b/src/SMESHGUI/SMESHGUI_MoveNodesDlg.cxx index e4bbc8bed..aaeaa4481 100644 --- a/src/SMESHGUI/SMESHGUI_MoveNodesDlg.cxx +++ b/src/SMESHGUI/SMESHGUI_MoveNodesDlg.cxx @@ -281,6 +281,22 @@ bool SMESHGUI_MoveNodesDlg::isValid (const bool theMess) tr("NODE_ID_IS_NOT_DEFINED")); return false; } + + QString msg; + bool ok = true; + ok = myX->isValid( msg, theMess ) && ok; + ok = myY->isValid( msg, theMess ) && ok; + ok = myZ->isValid( msg, theMess ) && ok; + if( !ok ) { + if( theMess ) { + QString str( tr( "SMESH_INCORRECT_INPUT" ) ); + if ( !msg.isEmpty() ) + str += "\n" + msg; + SUIT_MessageBox::critical( this, tr( "SMESH_ERROR" ), str ); + } + return false; + } + return true; } @@ -325,6 +341,12 @@ bool SMESHGUI_MoveNodesDlg::onApply() bool aResult = false; try { aResult = aMeshEditor->MoveNode(anId, myX->GetValue(), myY->GetValue(), myZ->GetValue()); + + QStringList aParameters; + aParameters << myX->text(); + aParameters << myY->text(); + aParameters << myZ->text(); + aMesh->SetParameters( SMESHGUI::JoinObjectParameters(aParameters) ); } catch (...) { }