From: eap Date: Mon, 22 Jul 2013 13:56:41 +0000 (+0000) Subject: Bug: mesh is not destructed (leaks) after element selection. X-Git-Tag: BR_hydro_v_0_3_1~105 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=240cb67632b657a69a8a34c6de098bb35e2502e0;p=modules%2Fgui.git Bug: mesh is not destructed (leaks) after element selection. + //! releaze myLastHighlitedActor and myLastPreHighlitedActor + void FreeActors(); --- diff --git a/src/SVTK/SVTK_InteractorStyle.cxx b/src/SVTK/SVTK_InteractorStyle.cxx index 7f7f5e6e7..ea8c11bd3 100644 --- a/src/SVTK/SVTK_InteractorStyle.cxx +++ b/src/SVTK/SVTK_InteractorStyle.cxx @@ -160,6 +160,15 @@ SVTK_Selector* SVTK_InteractorStyle::GetSelector() return myInteractor->GetSelector(); } +/*! + Realeaze actors +*/ +void SVTK_InteractorStyle::FreeActors() +{ + myLastHighlitedActor = NULL; + myLastPreHighlitedActor = NULL; +} + /*! Generate special SVTK_SelectionEvent */ diff --git a/src/SVTK/SVTK_InteractorStyle.h b/src/SVTK/SVTK_InteractorStyle.h index 4070d5516..e4a069bdb 100644 --- a/src/SVTK/SVTK_InteractorStyle.h +++ b/src/SVTK/SVTK_InteractorStyle.h @@ -245,6 +245,9 @@ class SVTK_EXPORT SVTK_InteractorStyle: public vtkInteractorStyle void SetAdvancedZoomingEnabled( const bool theState ) { myIsAdvancedZoomingEnabled = theState; } bool IsAdvancedZoomingEnabled() const { return myIsAdvancedZoomingEnabled; } + //! releaze myLastHighlitedActor and myLastPreHighlitedActor + void FreeActors(); + protected: SVTK_InteractorStyle(); ~SVTK_InteractorStyle();