Salome HOME
Merge remote-tracking branch 'remotes/origin/HighLevelDump'
[modules/shaper.git] / src / SketchPlugin / SketchPlugin_ConstraintHorizontal.cpp
index 722ea659a0f96a54bae1f5e9d0fb01b0487e8b39..558b44a3ddaa4aa6eea1af177f350db1f23579c2 100644 (file)
@@ -14,6 +14,7 @@
 #include <SketchPlugin_Sketch.h>
 
 #include <SketcherPrs_Factory.h>
+//#include <SketcherPrs_Tools.h>
 
 #include <Config_PropManager.h>
 
@@ -23,7 +24,7 @@ SketchPlugin_ConstraintHorizontal::SketchPlugin_ConstraintHorizontal()
 
 void SketchPlugin_ConstraintHorizontal::initAttributes()
 {
-  data()->addAttribute(SketchPlugin_Constraint::ENTITY_A(), ModelAPI_AttributeRefAttr::type());
+  data()->addAttribute(SketchPlugin_Constraint::ENTITY_A(), ModelAPI_AttributeRefAttr::typeId());
 }
 
 void SketchPlugin_ConstraintHorizontal::execute()
@@ -35,9 +36,8 @@ AISObjectPtr SketchPlugin_ConstraintHorizontal::getAISObject(AISObjectPtr thePre
   if (!sketch())
     return thePrevious;
 
-  AISObjectPtr anAIS = thePrevious;
-  /// TODO: Horizontal constraint presentation should be put here
+  AISObjectPtr anAIS = SketcherPrs_Factory::horisontalConstraint(this, sketch()->coordinatePlane(),
+                                                                 thePrevious);
   return anAIS;
 }
 
-