1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-14 13:30:48 +03:00

0027893: Visualization - AIS_InteractiveContext::SetSelected does not work

- misprint in check of global selection existence in AIS_InteractiveContext::SetSelected was corrected;
- remaining occurrencies of hard-coded 0 selection mode were corrected to use global selection mode;
- test case for issue #27983
This commit is contained in:
vpa
2016-09-26 20:34:26 +03:00
committed by kgv
parent 949c9b7f28
commit 0d5880e11a
5 changed files with 55 additions and 30 deletions

View File

@@ -370,9 +370,10 @@ void SelectMgr_SelectionManager::Activate (const Handle(SelectMgr_SelectableObje
if (myGlobal.Contains (theObject))
{
if (theMode != 0 && theSelector->IsActive (theObject, 0))
const Standard_Integer aGlobalSelMode = theObject->GlobalSelectionMode();
if (theMode != aGlobalSelMode && theSelector->IsActive (theObject, aGlobalSelMode))
{
theSelector->Deactivate (theObject->Selection (0));
theSelector->Deactivate (theObject->Selection (aGlobalSelMode));
}
theSelector->Activate (theObject->Selection (theMode));
}