]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
GUI for placement operation
authorvsv <vitaly.smetannikov@opencascade.com>
Tue, 2 Dec 2014 12:29:02 +0000 (15:29 +0300)
committervsv <vitaly.smetannikov@opencascade.com>
Tue, 2 Dec 2014 12:29:02 +0000 (15:29 +0300)
src/FeaturesPlugin/CMakeLists.txt
src/FeaturesPlugin/FeaturesPlugin_Plugin.cpp
src/FeaturesPlugin/placement_widget.xml [new file with mode: 0644]
src/FeaturesPlugin/plugin-Features.xml

index 406032e871b71dbd79d491641b7760b616de84de..3fd916de3f8f3dbb10378e52376fc6c66b58bba8 100644 (file)
@@ -22,6 +22,7 @@ SET(XML_RESOURCES
   extrusion_widget.xml
   boolean_widget.xml
   group_widget.xml
+  placement_widget.xml
 )
 
 INCLUDE_DIRECTORIES(
index 681479032f7c5359fec4cbd5bc425d4e9e59bb36..cd1ceb219dfc21f945721fab15a78315432c88c3 100644 (file)
@@ -3,6 +3,7 @@
 #include <FeaturesPlugin_Boolean.h>
 #include <FeaturesPlugin_Extrusion.h>
 #include <FeaturesPlugin_Group.h>
+#include <FeaturesPlugin_Placement.h>
 
 #include <ModelAPI_Session.h>
 
@@ -29,6 +30,8 @@ FeaturePtr FeaturesPlugin_Plugin::createFeature(string theFeatureID)
     return FeaturePtr(new FeaturesPlugin_Boolean);
   } else if (theFeatureID == FeaturesPlugin_Group::ID()) {
     return FeaturePtr(new FeaturesPlugin_Group);
+  } else if (theFeatureID == FeaturesPlugin_Placement::ID()) {
+    return FeaturePtr(new FeaturesPlugin_Placement);
   }
   // feature of such kind is not found
   return FeaturePtr();
diff --git a/src/FeaturesPlugin/placement_widget.xml b/src/FeaturesPlugin/placement_widget.xml
new file mode 100644 (file)
index 0000000..998b272
--- /dev/null
@@ -0,0 +1,16 @@
+<source>
+  <shape_selector id="placement_base_face" 
+    label="Select a face" 
+    icon=":icons/cut_shape.png" 
+    tooltip="Select a face a one object"
+    shape_types="face"
+    use_subshapes="true"
+  />
+  <shape_selector id="placement_attractable_face" 
+    label="Select a face" 
+    icon=":icons/cut_shape.png" 
+    tooltip="Select a face of another object"
+    shape_types="face"
+    use_subshapes="true"
+  />
+</source>
index 3c2dcc0d3a02fcc49301775112602de7f35168de..cbe584eab5ae511e4fdd3771d071964bb223f30d 100644 (file)
@@ -8,7 +8,7 @@
           <source path="boolean_widget.xml"/>
       </feature>
       <feature id="Placement" title="Placement" tooltip="Perform moving an object to specified position" icon="">
-<!--          <source path="extrusion_widget.xml"/>-->
+          <source path="placement_widget.xml"/>
       </feature>
     </group>
     <group id="Collections">