]> OCCT Git - occt-copy.git/commitdiff
temporary patch to avoid deactivate selection on children after the parent's hiding CR0_ALICONA
authoralex <alex>
Tue, 15 Oct 2019 11:59:45 +0000 (14:59 +0300)
committeralex <alex>
Tue, 15 Oct 2019 11:59:45 +0000 (14:59 +0300)
src/SelectMgr/SelectMgr_SelectionManager.cxx

index 195ed54c754b0a9cda1096a24d36adf518c1c813..aeb445aa912b17dd0e4be53bf6287109a21f14d6 100644 (file)
@@ -185,9 +185,12 @@ void SelectMgr_SelectionManager::Activate (const Handle(SelectMgr_SelectableObje
 void SelectMgr_SelectionManager::Deactivate (const Handle(SelectMgr_SelectableObject)& theObject,
                                              const Standard_Integer theMode)
 {
-  for (PrsMgr_ListOfPresentableObjectsIter anChildrenIter (theObject->Children()); anChildrenIter.More(); anChildrenIter.Next())
+  if (theObject->ToPropagateVisualState())
   {
-    Deactivate (Handle(SelectMgr_SelectableObject)::DownCast (anChildrenIter.Value()), theMode);
+    for (PrsMgr_ListOfPresentableObjectsIter anChildrenIter(theObject->Children()); anChildrenIter.More(); anChildrenIter.Next())
+    {
+      Deactivate(Handle(SelectMgr_SelectableObject)::DownCast(anChildrenIter.Value()), theMode);
+    }
   }
   if (!theObject->HasOwnPresentations())
   {