From f2b63181108fe76fc0c48938337e0788ea56c532 Mon Sep 17 00:00:00 2001 From: mgn Date: Tue, 24 May 2016 17:43:32 +0300 Subject: [PATCH] 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(). --- src/AIS/AIS_InteractiveContext.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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); } }