]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Exclude attribute "Auxiliary" from the Projection feature (issue #1459)
authorazv <azv@opencascade.com>
Thu, 28 Apr 2016 10:09:16 +0000 (13:09 +0300)
committerazv <azv@opencascade.com>
Thu, 28 Apr 2016 10:09:35 +0000 (13:09 +0300)
src/SketchPlugin/SketchPlugin_Projection.cpp
src/SketchPlugin/plugin-Sketch.xml

index 6240c933b2b54e2682e1ed1de001b46d54fe25bb..ac75866268be15785b903f86058a9a09015a262e 100644 (file)
@@ -45,6 +45,8 @@ void SketchPlugin_Projection::initDerivedClassAttributes()
 
   data()->addAttribute(EXTERNAL_ID(), ModelAPI_AttributeSelection::typeId());
   ModelAPI_Session::get()->validators()->registerNotObligatory(getKind(), EXTERNAL_ID());
+
+  ModelAPI_Session::get()->validators()->registerNotObligatory(getKind(), AUXILIARY_ID());
 }
 
 void SketchPlugin_Projection::execute()
@@ -76,16 +78,6 @@ void SketchPlugin_Projection::attributeChanged(const std::string& theID)
     computeProjection(theID);
     myIsComputing = false;
   }
-  else if (theID == AUXILIARY_ID())
-  {
-    AttributeRefAttrPtr aRefAttr = data()->refattr(PROJECTED_FEATURE_ID());
-    if (!aRefAttr || !aRefAttr->isInitialized())
-      return;
-    FeaturePtr aProjection = ModelAPI_Feature::feature(aRefAttr->object());
-    if (!aProjection)
-      return;
-    aProjection->boolean(AUXILIARY_ID())->setValue(boolean(AUXILIARY_ID())->value());
-  }
 }
 
 void SketchPlugin_Projection::computeProjection(const std::string& theID)
index dab490931354c0eabf96a90d63f9a3389b58fa44..96b230b55211f453ede4edfac9424c418e5a797f 100644 (file)
           <validator id="GeomValidators_ShapeType" parameters="line"/>
           <validator id="SketchPlugin_IntersectionValidator"/>
         </sketch_shape_selector>
-        <boolvalue id="Auxiliary" label="Auxiliary" default="false" tooltip="Construction element" obligatory="0"/>
       </feature -->
 
       <!-- Projected feature -->
               use_sketch_plane="false">
           <validator id="SketchPlugin_ProjectionValidator"/>
         </sketch_shape_selector>
-        <boolvalue id="Auxiliary" label="Auxiliary" default="false" tooltip="Construction element" obligatory="0"/>
       </feature>
     </group>