From: mgn Date: Tue, 24 May 2016 14:43:32 +0000 (+0300) Subject: 0027538: Visualization, AIS_InteractiveContext::Display() - do not erase previous... X-Git-Tag: V7_0_winwerth~38 X-Git-Url: http://git.dev.opencascade.org/gitweb/?a=commitdiff_plain;h=f2b63181108fe76fc0c48938337e0788ea56c532;p=occt-copy.git 0027538: Visualization, AIS_InteractiveContext::Display() - do not erase previous display mode. AIS_InteractiveContext::Display() does not erases old presentation modes of interactive object anymore giving us performance benefit AIS_InteractiveContext::Display() is used. Instead, the method marks them hidden in the same way as AIS_InteractiveContext::SetDisplayMode() and ::UnsetDisplayMode(). --- diff --git a/src/AIS/AIS_InteractiveContext.cxx b/src/AIS/AIS_InteractiveContext.cxx index c6c7f93d4e..867005e249 100644 --- a/src/AIS/AIS_InteractiveContext.cxx +++ b/src/AIS/AIS_InteractiveContext.cxx @@ -449,7 +449,7 @@ void AIS_InteractiveContext::Display (const Handle(AIS_InteractiveObject)& theIO return; } - // Erase presentations for all display modes different from aDispMode. + // Mark the presentation modes hidden of interactive object different from aDispMode. // Then make sure aDispMode is displayed and maybe highlighted. // Finally, activate selection mode if not yet activated. TColStd_ListOfInteger aModesToRemove; @@ -463,7 +463,7 @@ void AIS_InteractiveContext::Display (const Handle(AIS_InteractiveObject)& theIO { myMainPM->Unhighlight (theIObj, anOldMode); } - myMainPM->Erase (theIObj, anOldMode); + myMainPM->SetVisibility (theIObj, anOldMode, Standard_False); } }