Salome HOME
Issue #1502 Select sub-solids in viewer : set selection priority for the owner less...
[modules/shaper.git] / src / SketchPlugin / SketchPlugin_ConstraintVertical.cpp
index d5865e6ab3c14aafc6e2bb7da8fd13b75c992cd2..0520ca69ebca18eaeeeeda8364017347d5ea147b 100644 (file)
@@ -35,10 +35,8 @@ AISObjectPtr SketchPlugin_ConstraintVertical::getAISObject(AISObjectPtr thePrevi
   if (!sketch())
     return thePrevious;
 
-  AISObjectPtr anAIS = thePrevious;
-  if (!anAIS) {
-    anAIS = SketcherPrs_Factory::verticalConstraint(this, sketch()->coordinatePlane());
-  }
+  AISObjectPtr anAIS = SketcherPrs_Factory::verticalConstraint(this, sketch()->coordinatePlane(),
+                                                               thePrevious);
   return anAIS;
 }