From ad6e991b0289e8dc50624c9d45bc35363644c81d Mon Sep 17 00:00:00 2001 From: azv Date: Wed, 4 May 2016 17:03:26 +0300 Subject: [PATCH] Make the copies fixed in multi-rotation, multi-translation (issue #1471) --- src/SketchSolver/SketchSolver_Storage.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/SketchSolver/SketchSolver_Storage.cpp b/src/SketchSolver/SketchSolver_Storage.cpp index c63d28e43..d77c0d702 100644 --- a/src/SketchSolver/SketchSolver_Storage.cpp +++ b/src/SketchSolver/SketchSolver_Storage.cpp @@ -175,9 +175,9 @@ bool SketchSolver_Storage::update(FeaturePtr theFeature, const GroupID& theGroup BuilderPtr aBuilder = SketchSolver_Manager::instance()->builder(); GroupID aGroup = theGroup != GID_UNKNOWN ? theGroup : myGroupID; // Check external feature - std::shared_ptr aSketchFeature = - std::dynamic_pointer_cast(theFeature); - if (aSketchFeature && aSketchFeature->isExternal()) + std::shared_ptr aSketchFeature = + std::dynamic_pointer_cast(theFeature); + if (aSketchFeature && (aSketchFeature->isExternal() || aSketchFeature->isCopy())) aGroup = GID_OUTOFGROUP; aRelated = aBuilder->createFeature(theFeature, aSubs, aGroup); if (!aRelated) @@ -221,9 +221,9 @@ bool SketchSolver_Storage::update(AttributePtr theAttribute, const GroupID& theG BuilderPtr aBuilder = SketchSolver_Manager::instance()->builder(); GroupID aGroup = theGroup != GID_UNKNOWN ? theGroup : myGroupID; // Check attribute of external features - std::shared_ptr aSketchFeature = - std::dynamic_pointer_cast(theAttribute->owner()); - if (aSketchFeature && aSketchFeature->isExternal()) + std::shared_ptr aSketchFeature = + std::dynamic_pointer_cast(theAttribute->owner()); + if (aSketchFeature && (aSketchFeature->isExternal() || aSketchFeature->isCopy())) aGroup = GID_OUTOFGROUP; aRelated = aBuilder->createAttribute(anAttribute, aGroup); if (!aRelated) -- 2.39.2