]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Fix for the issue #1129
authormpv <mpv@opencascade.com>
Thu, 17 Dec 2015 15:17:46 +0000 (18:17 +0300)
committermpv <mpv@opencascade.com>
Thu, 17 Dec 2015 15:17:46 +0000 (18:17 +0300)
src/FeaturesPlugin/FeaturesPlugin_Placement.cpp
src/FeaturesPlugin/FeaturesPlugin_Translation.cpp

index 1fcfa7618e3d27a44f9e9f4f65b400ca9ad2f7f0..a8e4b4138432ec11bf105c68f40cee609bba59ca 100644 (file)
@@ -55,7 +55,8 @@ void FeaturesPlugin_Placement::execute()
   for(int anObjectsIndex = 0; anObjectsIndex < anObjectsSelList->size(); anObjectsIndex++) {
     std::shared_ptr<ModelAPI_AttributeSelection> anObjectAttr = anObjectsSelList->value(anObjectsIndex);
     std::shared_ptr<GeomAPI_Shape> anObject = anObjectAttr->value();
-    if(!anObject.get()) {
+    if(!anObject.get()) { // may be for not-activated parts
+      eraseResults();
       return;
     }
     anObjects.push_back(anObject);
index 423ea9459aed423d9865c008c595aa6452a20e6d..c55d23d818391355b24abc3609adda4dec98f075 100644 (file)
@@ -47,7 +47,8 @@ void FeaturesPlugin_Translation::execute()
   for(int anObjectsIndex = 0; anObjectsIndex < anObjectsSelList->size(); anObjectsIndex++) {
     std::shared_ptr<ModelAPI_AttributeSelection> anObjectAttr = anObjectsSelList->value(anObjectsIndex);
     std::shared_ptr<GeomAPI_Shape> anObject = anObjectAttr->value();
-    if(!anObject.get()) {
+    if(!anObject.get()) { // may be for not-activated parts
+      eraseResults();
       return;
     }
     anObjects.push_back(anObject);