Salome HOME
Issue #591 - Highlight of the first argument of constraints
[modules/shaper.git] / src / SketchSolver / SketchSolver_ConstraintCoincidence.cpp
index 04e6db8d21c62e7c460d973106f8c830f7c4b664..532097e9935d3b2deac470366824d307ee446953 100644 (file)
@@ -170,6 +170,12 @@ bool SketchSolver_ConstraintCoincidence::remove(ConstraintPtr theConstraint)
       return false; // there is no constraint, which is specified to remove
     else {
       bool isEmpty = anExtraIt->first == SLVS_E_UNKNOWN;
+      if (!isEmpty) {
+        for (aPos = 0; aPos < (int)mySlvsConstraints.size(); aPos++)
+          if (mySlvsConstraints[aPos] == anExtraIt->first)
+            break;
+        aPos -= 1;
+      }
       myExtraCoincidence.erase(anExtraIt);
       if (isEmpty)
         return false;