]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Debug of the "reversed" filters flag management.
authormpv <mpv@opencascade.com>
Tue, 4 Jun 2019 12:15:47 +0000 (15:15 +0300)
committermpv <mpv@opencascade.com>
Tue, 4 Jun 2019 12:15:47 +0000 (15:15 +0300)
src/FiltersPlugin/FiltersPlugin_Selection.cpp

index 025d30147b3b9c9883ed66f1303858fa3ad06d90..c89e909cc682082ccd1a4450648bfd0f2145eef5 100644 (file)
@@ -56,13 +56,15 @@ std::list<std::string> FiltersPlugin_Selection::filters() const
 
 void FiltersPlugin_Selection::setReversed(const std::string theFilterID, const bool theReversed)
 {
-  std::string anAttrID = kReverseAttrID + kFilterSeparator + theFilterID;
+  std::string anAttrID = theFilterID + kFilterSeparator + kReverseAttrID;
   std::shared_ptr<ModelAPI_AttributeBoolean> aBool = boolean(anAttrID);
+  if (aBool.get())
+    aBool->setValue(theReversed);
 }
 
 bool FiltersPlugin_Selection::isReversed(const std::string theFilterID)
 {
-  std::string anAttrID = kReverseAttrID + kFilterSeparator + theFilterID;
+  std::string anAttrID = theFilterID + kFilterSeparator + kReverseAttrID;
   std::shared_ptr<ModelAPI_AttributeBoolean> aBool = boolean(anAttrID);
   return aBool->value();
 }