]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Fixed coding issues
authorJérôme <jerome.lucas@cesgenslab.fr>
Tue, 8 Dec 2020 09:12:25 +0000 (10:12 +0100)
committerJérôme <jerome.lucas@cesgenslab.fr>
Tue, 8 Dec 2020 09:12:25 +0000 (10:12 +0100)
src/FeaturesPlugin/BoundingBox_widget.xml [deleted file]
src/FeaturesPlugin/Bounding_Box_widget.xml [new file with mode: 0644]
src/FeaturesPlugin/CMakeLists.txt
src/FeaturesPlugin/CreateBoundingBox_widget.xml [deleted file]
src/FeaturesPlugin/Create_Bounding_Box_widget.xml [new file with mode: 0644]
src/FeaturesPlugin/FeaturesPlugin_BoundingBox.cpp
src/FeaturesPlugin/FeaturesPlugin_CommonBoundingBox.cpp
src/FeaturesPlugin/FeaturesPlugin_CommonBoundingBox.h
src/FeaturesPlugin/FeaturesPlugin_CreateBoundingBox.cpp
src/FeaturesPlugin/plugin-Features.xml

diff --git a/src/FeaturesPlugin/BoundingBox_widget.xml b/src/FeaturesPlugin/BoundingBox_widget.xml
deleted file mode 100644 (file)
index 0dc8a0d..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-<source>
-  <shape_selector id="main_objects"
-                  label="Object"
-                  tooltip="Select a object"
-                  shape_types="vertex edge face solid compsolid compound object"
-                  default=""
-                  geometrical_selection="true">
-    <validator id="PartSet_DifferentObjects"/>
-    <validator id="GeomValidators_ShapeType" parameters="vertex,line,edge,wire,face,shell,solid,compsolid,compound"/>
-  </shape_selector>
-  <groupbox title="Min">
-    <label id="xmincoordinate" isSelectable = "true"/>
-    <label id="ymincoordinate" isSelectable = "true"/>
-    <label id="zmincoordinate" isSelectable = "true"/>
-  </groupbox>
-  <groupbox title="Max">
-    <label id="xmaxcoordinate" isSelectable = "true"/>
-    <label id="ymaxcoordinate" isSelectable = "true"/>
-    <label id="zmaxcoordinate" isSelectable = "true"/>
-  </groupbox>
-  <boolvalue id="createbox" label="Create box" default="false"/>
-</source>
diff --git a/src/FeaturesPlugin/Bounding_Box_widget.xml b/src/FeaturesPlugin/Bounding_Box_widget.xml
new file mode 100644 (file)
index 0000000..0dc8a0d
--- /dev/null
@@ -0,0 +1,22 @@
+<source>
+  <shape_selector id="main_objects"
+                  label="Object"
+                  tooltip="Select a object"
+                  shape_types="vertex edge face solid compsolid compound object"
+                  default=""
+                  geometrical_selection="true">
+    <validator id="PartSet_DifferentObjects"/>
+    <validator id="GeomValidators_ShapeType" parameters="vertex,line,edge,wire,face,shell,solid,compsolid,compound"/>
+  </shape_selector>
+  <groupbox title="Min">
+    <label id="xmincoordinate" isSelectable = "true"/>
+    <label id="ymincoordinate" isSelectable = "true"/>
+    <label id="zmincoordinate" isSelectable = "true"/>
+  </groupbox>
+  <groupbox title="Max">
+    <label id="xmaxcoordinate" isSelectable = "true"/>
+    <label id="ymaxcoordinate" isSelectable = "true"/>
+    <label id="zmaxcoordinate" isSelectable = "true"/>
+  </groupbox>
+  <boolvalue id="createbox" label="Create box" default="false"/>
+</source>
index ec8382c3ed855148fc0d37f10acfaebdbb7cb659..446b32b9dee40008804fb29368be77bdd01a1f7a 100644 (file)
@@ -24,7 +24,6 @@ INCLUDE(UseQtExt)
 # additional include directories
 INCLUDE_DIRECTORIES( ${PROJECT_SOURCE_DIR}/src/GeomDataAPI
                      ${PROJECT_SOURCE_DIR}/src/Locale
-                     ${PROJECT_SOURCE_DIR}/src/PrimitivesPlugin
                      ${QT_INCLUDES})
 
 # additional preprocessor / compiler flags
@@ -164,8 +163,8 @@ SET(XML_RESOURCES
   fillet1d_widget.xml
   measurement_widget.xml
   GeometryCalculation_widget.xml
-  BoundingBox_widget.xml
-  CreateBoundingBox_widget.xml
+  Bounding_Box_widget.xml
+  Create_Bounding_Box_widget.xml
   fusion_faces_widget.xml
   chamfer_widget.xml
   copy_widget.xml
diff --git a/src/FeaturesPlugin/CreateBoundingBox_widget.xml b/src/FeaturesPlugin/CreateBoundingBox_widget.xml
deleted file mode 100644 (file)
index 02cb648..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-<source>
-  <shape_selector id="main_objects"
-                  label="Object"
-                  tooltip="Select a object"
-                  shape_types="vertex edge face solid compsolid compound object"
-                  default=""
-                  geometrical_selection="true">
-    <validator id="PartSet_DifferentObjects"/>
-    <validator id="GeomValidators_ShapeType" parameters="vertex,line,edge,wire,face,shell,solid,compsolid,compound"/>
-  </shape_selector>
-  <groupbox title="Min">
-    <label id="xmincoordinate" isSelectable = "true"/>
-    <label id="ymincoordinate" isSelectable = "true"/>
-    <label id="zmincoordinate" isSelectable = "true"/>
-  </groupbox>
-  <groupbox title="Max">
-    <label id="xmaxcoordinate" isSelectable = "true"/>
-    <label id="ymaxcoordinate" isSelectable = "true"/>
-    <label id="zmaxcoordinate" isSelectable = "true"/>
-  </groupbox>
-</source>
diff --git a/src/FeaturesPlugin/Create_Bounding_Box_widget.xml b/src/FeaturesPlugin/Create_Bounding_Box_widget.xml
new file mode 100644 (file)
index 0000000..02cb648
--- /dev/null
@@ -0,0 +1,21 @@
+<source>
+  <shape_selector id="main_objects"
+                  label="Object"
+                  tooltip="Select a object"
+                  shape_types="vertex edge face solid compsolid compound object"
+                  default=""
+                  geometrical_selection="true">
+    <validator id="PartSet_DifferentObjects"/>
+    <validator id="GeomValidators_ShapeType" parameters="vertex,line,edge,wire,face,shell,solid,compsolid,compound"/>
+  </shape_selector>
+  <groupbox title="Min">
+    <label id="xmincoordinate" isSelectable = "true"/>
+    <label id="ymincoordinate" isSelectable = "true"/>
+    <label id="zmincoordinate" isSelectable = "true"/>
+  </groupbox>
+  <groupbox title="Max">
+    <label id="xmaxcoordinate" isSelectable = "true"/>
+    <label id="ymaxcoordinate" isSelectable = "true"/>
+    <label id="zmaxcoordinate" isSelectable = "true"/>
+  </groupbox>
+</source>
index 0b92fcea4bc85e6e90eb6d437cf7fadc1d8a59e5..e105a419c5f2c9a72db561772cedab0fab249471 100644 (file)
 
 #include "FeaturesPlugin_BoundingBox.h"
 
+#include <Config_PropManager.h>
+
+#include <FeaturesPlugin_CreateBoundingBox.h>
+
+#include <GeomAlgoAPI_BoundingBox.h>
+
 #include <ModelAPI_AttributeSelection.h>
 #include <ModelAPI_AttributeDoubleArray.h>
 #include <ModelAPI_AttributeBoolean.h>
 #include <ModelAPI_AttributeString.h>
-
-#include <GeomAlgoAPI_BoundingBox.h>
-
 #include <ModelAPI_Data.h>
 #include <ModelAPI_Session.h>
 #include <ModelAPI_Validator.h>
-#include <Config_PropManager.h>
-
-#include <FeaturesPlugin_CreateBoundingBox.h>
 
 #include <iomanip>
 #include <sstream>
index 6edc825909ba6ef90969e7fa47256cb89a29f20a..63047c5b8716cf1c12fbd6215eed1e59e4d51842 100644 (file)
 
 #include "FeaturesPlugin_CommonBoundingBox.h"
 
-#include <ModelAPI_AttributeSelection.h>
 #include <ModelAPI_AttributeDoubleArray.h>
-#include <ModelAPI_AttributeBoolean.h>
-#include <ModelAPI_AttributeDouble.h>
-#include <GeomAlgoAPI_BoundingBox.h>
-#include <ModelAPI_AttributeString.h>
+
 #include <ModelAPI_Data.h>
+#include <ModelAPI_ResultBody.h>
 #include <ModelAPI_Session.h>
 #include <ModelAPI_Validator.h>
-#include <GeomAlgoAPI_PointBuilder.h>
 #include <GeomAPI_Vertex.h>
-#include <Config_PropManager.h>
-#include <ModelAPI_ResultBody.h>
+
+#include <GeomAlgoAPI_BoundingBox.h>
+#include <GeomAlgoAPI_PointBuilder.h>
 #include <GeomAlgoAPI_ShapeTools.h>
 
-#include <PrimitivesPlugin_Box.h>
+#include <Config_PropManager.h>
 
 #include <iomanip>
 #include <sstream>
-#include <iostream>
+
 
 
 //=================================================================================================
@@ -52,14 +49,14 @@ void FeaturesPlugin_CommonBoundingBox::createBoxByTwoPoints()
   DocumentPtr aDoc =  aSession->activeDocument();
 
   GeomVertexPtr vertexFirst =
-          GeomAlgoAPI_PointBuilder::vertex( aValues->value(0),
-                                            aValues->value(2),
-                                            aValues->value(4));
+          GeomAlgoAPI_PointBuilder::vertex(aValues->value(0),
+                                           aValues->value(2),
+                                           aValues->value(4));
 
   GeomVertexPtr  vertexSecond =
-          GeomAlgoAPI_PointBuilder::vertex( aValues->value(1),
-                                            aValues->value(3),
-                                            aValues->value(5));
+          GeomAlgoAPI_PointBuilder::vertex(aValues->value(1),
+                                           aValues->value(3),
+                                           aValues->value(5));
 
 
   std::shared_ptr<GeomAlgoAPI_Box> aBoxAlgo;
index 18ba7597209b741203109b8457a0c6c6c3cb575c..dc6e7b125a68542036c62f964659a02d8f632122 100644 (file)
 #include "FeaturesPlugin.h"
 #include <ModelAPI_Feature.h>
 
+#include <GeomAlgoAPI_Box.h>
+
 #include <GeomAPI_IPresentable.h>
 #include <GeomAPI_IScreenParams.h>
-#include <GeomAlgoAPI_Box.h>
 
 #include <ModelAPI_Attribute.h>
 
index df636ce899f220b24b87041f2b7ed3ed6cf3be8a..5a4b8ba46f3ea05e309f7a342497771af4176ae0 100644 (file)
@@ -21,7 +21,6 @@
 
 #include <ModelAPI_AttributeSelection.h>
 #include <ModelAPI_AttributeDoubleArray.h>
-#include <ModelAPI_AttributeBoolean.h>
 #include <ModelAPI_AttributeString.h>
 
 #include <ModelAPI_Data.h>
@@ -33,8 +32,6 @@
 #include <Config_PropManager.h>
 #include <ModelAPI_ResultBody.h>
 
-#include <PrimitivesPlugin_Box.h>
-
 #include <iomanip>
 #include <sstream>
 
@@ -103,10 +100,10 @@ void FeaturesPlugin_CreateBoundingBox::updateValues()
     if (!aShape && aSelection->context())
       aShape = aSelection->context()->shape();
   }
-  if (aShape){
+  if (aShape) {
     double aXmin, aXmax, aYmin,aYmax,aZmin,aZmax;
           std::string aError;
-    if!GetBoundingBox(aShape,
+    if (!GetBoundingBox(aShape,
                         true,
                         aXmin, aXmax,
                         aYmin,aYmax,
index cc9dbccc3d20588cf951dca8c22841d8b37d2fcf..5de92e7cd11ade6a64bba47fed8f95c25a92729e 100644 (file)
       </feature>
       <feature id="BoundingBoxMacro" title="Bounding box" tooltip="Calculate the bounding box" auto_preview="true"
                icon="icons/Features/bounding.png" helpfile="boundingBoxFeature.html"> 
-        <source path="BoundingBox_widget.xml"/>
+        <source path="Bounding_Box_widget.xml"/>
       </feature>
       <feature id="BoundingBox" title="Bounding box" tooltip="Calculate the bounding box" auto_preview="true"
                icon="icons/Features/bounding.png" helpfile="boundingBoxFeature.html" internal="1"> 
-        <source path="CreateBoundingBox_widget.xml"/>
+        <source path="Create_Bounding_Box_widget.xml"/>
       </feature>
       <feature id="Measurement" title="Measurement" tooltip="Calculate properties of objects"
                icon="icons/Features/measurement.png" helpfile="measurementFeature.html" abort_confirmation="false">