From ba382e61dbc100e3bf1d00eef7a1106a3ec57ea3 Mon Sep 17 00:00:00 2001 From: alex Date: Tue, 15 Oct 2019 14:59:45 +0300 Subject: [PATCH] temporary patch to avoid deactivate selection on children after the parent's hiding --- src/SelectMgr/SelectMgr_SelectionManager.cxx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/SelectMgr/SelectMgr_SelectionManager.cxx b/src/SelectMgr/SelectMgr_SelectionManager.cxx index 195ed54c75..aeb445aa91 100644 --- a/src/SelectMgr/SelectMgr_SelectionManager.cxx +++ b/src/SelectMgr/SelectMgr_SelectionManager.cxx @@ -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()) { -- 2.39.5