]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Fix for the issue #1504 : parameter in Part may refer to any parameter in PartSet
authormpv <mpv@opencascade.com>
Mon, 30 May 2016 08:06:35 +0000 (11:06 +0300)
committermpv <mpv@opencascade.com>
Mon, 30 May 2016 08:06:35 +0000 (11:06 +0300)
src/ModelAPI/ModelAPI_Tools.cpp

index 1270db2ec520b7567234588d68190305a0e42f2a..922bad719dc152adc287359167ff794a928111e4 100755 (executable)
@@ -159,14 +159,9 @@ bool findVariable(FeaturePtr theSearcher, const std::string& theName, double& ou
     return true;
   DocumentPtr aRootDocument = aSession->moduleDocument();
   if (aDocument != aRootDocument) {
-    ResultPtr aPartResult = findPartResult(aRootDocument, aDocument);
-    if (aPartResult.get()) {
-      FeaturePtr aPartFeature;
-      if (theSearcher.get()) // only if the relative search is needed
-        aPartFeature = aRootDocument->feature(aPartResult);
-      if (findVariable(aRootDocument, aPartFeature, theName, outValue, theParam))
-        return true;
-    }
+    // any parameters in PartSet is okindependently on the Part position (issu #1504)
+    if (findVariable(aRootDocument, FeaturePtr(), theName, outValue, theParam))
+      return true;
   }
   return false;
 }