Salome HOME
Small formatting and fix of addCircle
[modules/shaper.git] / src / SketcherPrs / SketcherPrs_Mirror.cpp
index 7218e9ead3043018dd2cc8336ef35e36319be19c..30bbc6ec33ceba0d29740ace179e984cf1bf37bf 100644 (file)
@@ -57,7 +57,7 @@ bool SketcherPrs_Mirror::IsReadyToDisplay(ModelAPI_Feature* theConstraint,
   return aReadyToDisplay;
 }
 
-bool SketcherPrs_Mirror::updatePoints(double theStep) const
+bool SketcherPrs_Mirror::updateIfReadyToDisplay(double theStep) const
 {
   if (!IsReadyToDisplay(myConstraint, myPlane))
     return false;
@@ -89,6 +89,8 @@ bool SketcherPrs_Mirror::updatePoints(double theStep) const
   // Get position of each mirrored object
   for (i = 0; i < aNb; i++) {
     aObj = anAttrC->object(i);
+    if (SketcherPrs_Tools::getShape(aObj).get() == NULL)
+      continue;
     aP1 = aMgr->getPosition(aObj, this, theStep);
     myPntArray->SetVertice(aNb + i + 1, aP1);
   }