XTSplitterWnd and Cleanup |
Post Reply |
Author | |
MarcoNedwig
Newbie Joined: 13 May 2004 Status: Offline Points: 1 |
Post Options
Thanks(0)
Posted: 13 May 2004 at 5:04pm |
I have a problem using XTSplitterWnd. When I call ReplaceView fiunction the old view is only set to SW_HIDE to activate another view with SW_SHOW. But the old view won't be destroyed and so the application has a memory leak, because the old view isn't set active anymore and memory stays allocated I solved the problem by doing pOldView->DestroyWindow at the end of the function, but this causes any function at the old view (like OnKillFocus methods) will cause errors, because the view doesn't exist anymore. My actual way is saving the return value of ReplaceView ( which is the pointer to the old view set to SW_HIDE) and call destroy window after a while ( 30 s). This causes an endless loops after a while( Perhaps a recursive call in DestroyWindow implementation of the MFC). This can be seen with WIN NT 4. WIN 2000 doesn't seem to have this behaviour? Does anyone has a suggestion or a solution for me? |
|
thodgson
Groupie Joined: 11 August 2003 Status: Offline Points: 78 |
Post Options
Thanks(0)
|
I am using ReplaceView in my application and was wondering if this issue has been addressed.
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |