Salome HOME
Problems found due to execution of MESH-075 GUI scenario
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_MakeNodeAtPointDlg.cxx
index 970500e69d7f60d60c8abd5e20da97d695ab7b48..2754b34a92436c064a1a15b786e5bdc3d0ac919b 100644 (file)
@@ -716,17 +716,17 @@ void SMESHGUI_MakeNodeAtPointOp::redisplayPreview()
                 myDlg->myDestinationZ->SetValue(z);
               }
               if ( myDestCoordChanged ) {
-                dx = myDlg->myDestinationX->GetValue() - myDlg->myCurrentX->GetValue();
-                dy = myDlg->myDestinationY->GetValue() - myDlg->myCurrentY->GetValue();
-                dz = myDlg->myDestinationZ->GetValue() - myDlg->myCurrentZ->GetValue();
+                dx = myDlg->myDestinationX->GetValue() - x;
+                dy = myDlg->myDestinationY->GetValue() - y;
+                dz = myDlg->myDestinationZ->GetValue() - z;
                 myDlg->myDestDX->SetValue(dx);
                 myDlg->myDestDY->SetValue(dy);
                 myDlg->myDestDZ->SetValue(dz);
               }
               else {
-                dx = myDlg->myDestDX->GetValue() + myDlg->myCurrentX->GetValue();;
-                dy = myDlg->myDestDY->GetValue() + myDlg->myCurrentY->GetValue();;
-                dz = myDlg->myDestDZ->GetValue() + myDlg->myCurrentZ->GetValue();;
+                dx = myDlg->myDestDX->GetValue() + x;
+                dy = myDlg->myDestDY->GetValue() + y;
+                dz = myDlg->myDestDZ->GetValue() + z;
                 myDlg->myDestinationX->SetValue(dx);
                 myDlg->myDestinationY->SetValue(dy);
                 myDlg->myDestinationZ->SetValue(dz);