]> SALOME platform Git repositories - modules/shaper.git/blobdiff - src/ModelAPI/ModelAPI_Feature.cpp
Salome HOME
AutoColor removed from Preferences and Doc update
[modules/shaper.git] / src / ModelAPI / ModelAPI_Feature.cpp
index 7e408e3a3bb9cdc39a012015c0af02b5e9c99e25..3c1e2bec8fb2304a7ad0ded67d2dddb5ee889bff 100644 (file)
@@ -74,17 +74,12 @@ void ModelAPI_Feature::setResult(const std::shared_ptr<ModelAPI_Result>& theResu
   if (!isDisabled()) // disabled feature may be executed when it is added as not enabled (#2078)
     theResult->setDisabled(theResult, false);
 
-  Config_Prop* aProp = Config_PropManager::findProp("Visualization", "result_group_auto_color");
-
-  if (aProp) {
-    bool anIsAutoColor = Config_PropManager::boolean("Visualization", "result_group_auto_color");
-
-    if (anIsAutoColor && theResult->groupName() == ModelAPI_ResultGroup::group()) {
+    if (Config_PropManager::getAutoColorStatus()
+                            && theResult->groupName() == ModelAPI_ResultGroup::group()) {
       std::vector<int> aColor;
       ModelAPI_Tools::findRandomColor(aColor);
       ModelAPI_Tools::setColor(theResult,  aColor);
     }
-  }
 }
 
 void ModelAPI_Feature::setResult(const std::shared_ptr<ModelAPI_Result>& theResult,