Salome HOME
Merge branch 'master' of newgeom:newgeom.git
[modules/shaper.git] / src / SketchPlugin / SketchPlugin_Constraint.cpp
index 6269e321360a820bbc535036a8db942b849a8dc0..70e4d7be6d96affc0c23c53d8980c3fdee2082ce 100644 (file)
@@ -4,39 +4,8 @@
 
 #include "SketchPlugin_Constraint.h"
 
-#include <ModelAPI_Data.h>
-#include <SketchPlugin_Sketch.h>
-
-const boost::shared_ptr<GeomAPI_Shape>& SketchPlugin_Constraint::preview()
-{
-  return getPreview();
-}
-
-void SketchPlugin_Constraint::addConstrainedObject(
-          const std::string&                                    theAttrID,
-          const boost::shared_ptr<ModelAPI_AttributeReference>& theReference)
-{
-  if (!data()->attribute(theAttrID).get())
-    data()->addAttribute(theAttrID, theReference->type());
-  boost::dynamic_pointer_cast<ModelAPI_AttributeReference>(
-    data()->attribute(theAttrID))->setValue(theReference->value());
-}
-
-void SketchPlugin_Constraint::addConstrainedObject(
-          const std::string&                                  theAttrID,
-          const boost::shared_ptr<ModelAPI_AttributeRefAttr>& theReference)
-{
-  if (!data()->attribute(theAttrID).get())
-    data()->addAttribute(theAttrID, theReference->type());
-  boost::dynamic_pointer_cast<ModelAPI_AttributeRefAttr>(
-    data()->attribute(theAttrID))->setValue(theReference->value());
-}
-
-void SketchPlugin_Constraint::getSketchParameters(
-          std::list< boost::shared_ptr<ModelAPI_Attribute> >& theParams)
-{
-  theParams.push_back(sketch()->data()->attribute(SKETCH_ATTR_ORIGIN));
-  theParams.push_back(sketch()->data()->attribute(SKETCH_ATTR_DIRX));
-  theParams.push_back(sketch()->data()->attribute(SKETCH_ATTR_DIRY));
-  theParams.push_back(sketch()->data()->attribute(SKETCH_ATTR_NORM));
+boost::shared_ptr<GeomAPI_AISObject> SketchPlugin_Constraint::getAISObject(
+                              boost::shared_ptr<GeomAPI_AISObject> thePrevious)
+{ 
+  return thePrevious;
 }