From 6dd14c57a48fe9250bec3abf47b169cc3468b88d Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Wed, 24 Oct 2007 23:27:57 +0000 Subject: [PATCH] release update region as soon as we finished painting the window instead of keeping it indefinitely (bug 1819635) [backport from trunk] git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@49412 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/msw/window.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/msw/window.cpp b/src/msw/window.cpp index 5b645530bc..2cee2bc994 100644 --- a/src/msw/window.cpp +++ b/src/msw/window.cpp @@ -4528,6 +4528,10 @@ bool wxWindowMSW::HandlePaint() eventNc.SetEventObject(this); GetEventHandler()->ProcessEvent(eventNc); + // don't keep an HRGN we don't need any longer (GetUpdateRegion() can only + // be called from inside the event handlers called above) + m_updateRegion.Clear(); + return processed; }