Salome HOME
2.5. Select the point of a sketch entity must display the editing point panel
[modules/shaper.git] / src / SketchPlugin / SketchPlugin_ConstraintCollinear.cpp
1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D -->
2
3 // File:    SketchPlugin_ConstraintCollinear.cpp
4 // Created: 26 May 2014
5 // Author:  Artem ZHIDKOV
6
7 #include "SketchPlugin_ConstraintCollinear.h"
8
9 SketchPlugin_ConstraintCollinear::SketchPlugin_ConstraintCollinear()
10 {
11 }
12
13 void SketchPlugin_ConstraintCollinear::initAttributes()
14 {
15   data()->addAttribute(SketchPlugin_Constraint::ENTITY_A(), ModelAPI_AttributeRefAttr::typeId());
16   data()->addAttribute(SketchPlugin_Constraint::ENTITY_B(), ModelAPI_AttributeRefAttr::typeId());
17 }
18
19 void SketchPlugin_ConstraintCollinear::execute()
20 {
21 }
22
23 AISObjectPtr SketchPlugin_ConstraintCollinear::getAISObject(AISObjectPtr thePrevious)
24 {
25   if (!sketch())
26     return thePrevious;
27
28   AISObjectPtr anAIS = thePrevious;
29   if (!anAIS) {
30     // TODO
31     //anAIS = SketcherPrs_Factory::collinearConstraint(this, sketch()->coordinatePlane());
32   }
33   return anAIS;
34 }
35
36