1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-08 18:40:55 +03:00

0025661: Visualization - AIS_InteractiveContext::Load() is not symmetric to the local context method

Register theIObj in the selection manager to prepare further activation of selection
This commit is contained in:
san 2014-12-25 19:09:57 +03:00 committed by abv
parent cbff1e5531
commit 89cc29b0b5

View File

@ -471,14 +471,22 @@ void AIS_InteractiveContext::Load (const Handle(AIS_InteractiveObject)& theIObj,
} }
if (theSelMode == -1 if (theSelMode == -1
&& !theToAllowDecomposition && !theToAllowDecomposition)
&& !myObjects.IsBound (theIObj)) {
if (!myObjects.IsBound (theIObj))
{ {
Standard_Integer aDispMode, aHiMod, aSelModeDef; Standard_Integer aDispMode, aHiMod, aSelModeDef;
GetDefModes (theIObj, aDispMode, aHiMod, aSelModeDef); GetDefModes (theIObj, aDispMode, aHiMod, aSelModeDef);
Handle(AIS_GlobalStatus) aStatus = new AIS_GlobalStatus (AIS_DS_Erased, aDispMode, aSelModeDef); Handle(AIS_GlobalStatus) aStatus = new AIS_GlobalStatus (AIS_DS_Erased, aDispMode, aSelModeDef);
myObjects.Bind (theIObj, aStatus); myObjects.Bind (theIObj, aStatus);
} }
// Register theIObj in the selection manager to prepare further activation of selection
if (!mgrSelector->Contains (theIObj))
{
mgrSelector->Load (theIObj);
}
}
} }
//======================================================================= //=======================================================================