]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
INT PAL 0052642: Notebook variables are not dumped to script with Fillet1D, Fillet2D...
authormpa <mpa@opencascade.com>
Thu, 26 Mar 2015 08:08:05 +0000 (11:08 +0300)
committermpa <mpa@opencascade.com>
Thu, 26 Mar 2015 08:08:05 +0000 (11:08 +0300)
src/GEOM_SWIG/geomBuilder.py
src/OperationGUI/OperationGUI_Fillet1d2dDlg.cxx
src/TransformationGUI/TransformationGUI_ProjectionOnCylDlg.cxx

index 5287a11948ca53982fa3baccb902c992cbefcd3b..e5c2bd608d27b2ff85f5bbab04df8bdbc473ff87 100644 (file)
@@ -9455,8 +9455,18 @@ class geomBuilder(object, GEOM._objref_GEOM_Gen):
                 the source shape onto a cylinder.
             """
             # Example: see GEOM_TestAll.py
+            flagStartAngle = False
+            if isinstance(theStartAngle,str):
+                flagStartAngle = True
+            flagAngleLength = False
+            if isinstance(theAngleLength,str):
+                flagAngleLength = True
             theRadius, theStartAngle, theAngleLength, Parameters = ParseParameters(
               theRadius, theStartAngle, theAngleLength)
+            if flagStartAngle:
+                theStartAngle = theStartAngle*math.pi/180.
+            if flagAngleLength:
+                theAngleLength = theAngleLength*math.pi/180.
             anObj = self.TrsfOp.MakeProjectionOnCylinder(theObject, theRadius,
                 theStartAngle, theAngleLength)
             RaiseIfFailed("MakeProjectionOnCylinder", self.TrsfOp)
index dbbae029770a159a8a91e433a3a1051086de910d..2de8fbc4004699b89b3f993d5e9131b17bbf046b 100644 (file)
@@ -411,8 +411,14 @@ bool OperationGUI_Fillet1d2dDlg::execute (ObjectList& objects)
     anOper->MakeFillet1D(myShape, getRadius(), aListOfIndexes, GroupVertexes->CheckButton1->isChecked()) : 
     anOper->MakeFillet2D(myShape, getRadius(), aListOfIndexes);
 
-  if (!anObj->_is_nil())
+  if (!anObj->_is_nil()) {
+    if (!IsPreview()) {
+      QStringList aParameters;
+      aParameters << GroupVertexes->SpinBox_DX->text();
+      anObj->SetParameters(aParameters.join(":").toUtf8().constData());
+    }
     objects.push_back(anObj._retn());
+  }
 
   return true;
 }
index d3efac6415eb3334cd2484b134e8d40eeaafbf4c..7c5dd617699e515d1e9fa6509832f3e1b30bb8e7 100644 (file)
@@ -353,6 +353,14 @@ bool TransformationGUI_ProjectionOnCylDlg::execute (ObjectList& objects)
     (myObj, aRadius, aStartAngle, aLengthAngle);
 
   if (!anObj->_is_nil()) {
+    if (!IsPreview()) {
+      QStringList aParameters;
+      aParameters << myRadiusSpin->text();
+      aParameters << myStartAngleSpin->text();
+      if (myUseAngleLen->isChecked())
+        aParameters << myAngleLenSpin->text();
+      anObj->SetParameters(aParameters.join(":").toUtf8().constData());
+    }
     objects.push_back(anObj._retn());
   }