Salome HOME
Remove redundant code
[modules/geom.git] / src / EntityGUI / EntityGUI_SketcherDlg.cxx
index fde880b435ff86b93d04d8b036b20a894c0f582e..f489c89c2e029bc718fbfe6847c2e44a7f2c6227 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2007-2014  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2015  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
@@ -47,6 +47,7 @@
 #include <SalomeApp_Application.h>
 #include <LightApp_Application.h>
 #include <LightApp_SelectionMgr.h>
+#include "utilities.h"
 
 #include <DlgRef.h>
 
@@ -64,6 +65,7 @@
 
 #include <SalomeApp_Study.h>
 #include <SalomeApp_Tools.h>
+#include "utilities.h"
 
 #include <gp_Pln.hxx>
 
@@ -630,15 +632,14 @@ void EntityGUI_SketcherDlg::RectClicked()
        SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) );
   
   GroupRect->show();
-  
   myX1=0;
-  myX2=10;
-  myY1=0;
-  myY2=10;
-
   GroupRect->SpinBox_DX1->setValue(myX1); 
+  myY1=0;
   GroupRect->SpinBox_DY1->setValue(myY1);
+  myX2=10;
   GroupRect->SpinBox_DX2->setValue(myX2);
+  myY2=10;
   GroupRect->SpinBox_DY2->setValue(myY2);
   
   resize( minimumSizeHint() );
@@ -2258,7 +2259,7 @@ QString EntityGUI_SketcherDlg::GetNewCommand( QString& theParameters )
                                   + ":TT " + QString::number( myX2, Format, DigNum) + " " + QString::number( myY1, Format, DigNum)
                                   + ":WW";
                           
-      theParameters = myX1Str + ":" + myY1Str + ":" + myX2Str + ":" + myY2Str ;
+      theParameters = myX1Str + ":" + myY1Str + ":" + myX1Str + ":" + myY2Str + ":" + myX2Str + ":" + myY2Str + ":" + myX2Str + ":" + myY1Str;
     }
   return myNewCommand;
 }