From: apo Date: Mon, 3 Oct 2005 06:20:41 +0000 (+0000) Subject: To provide correct memory management X-Git-Tag: BR-D5-38-2003_D2005-12-10~25 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=4051aef42ed4ff514a8d84f1b2de5dc1ca4992b3;p=modules%2Fgui.git To provide correct memory management --- diff --git a/src/SVTK/SVTK_RenderWindowInteractor.cxx b/src/SVTK/SVTK_RenderWindowInteractor.cxx index 606c3d546..74a930ab0 100644 --- a/src/SVTK/SVTK_RenderWindowInteractor.cxx +++ b/src/SVTK/SVTK_RenderWindowInteractor.cxx @@ -61,8 +61,10 @@ using namespace std; #ifdef _DEBUG_ static int MYDEBUG = 0; +static int MYVTKDEBUG = 0; #else static int MYDEBUG = 0; +static int MYVTKDEBUG = 0; #endif static bool GENERATE_SUIT_EVENTS = false; @@ -409,10 +411,16 @@ SVTK_RenderWindowInteractor // Sequence of the destruction call are fixed and should be changed. // vtkRenderWindow instance should be destroyed after all vtkRenderer's + if(MYVTKDEBUG){ + getRenderWindow()->DebugOn(); + getRenderer()->DebugOn(); + GetDevice()->DebugOn(); + } GetDevice()->SetInteractorStyle(NULL); while(!myInteractorStyles.empty()){ const PInteractorStyle& aStyle = myInteractorStyles.top(); aStyle->SetInteractor(NULL); + if(MYVTKDEBUG) aStyle->DebugOn(); myInteractorStyles.pop(); }