From a6d74d8176e35e0233ed4f39c63d7298e92d6f3d Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Fri, 9 Jan 2015 03:30:10 +0000 Subject: [PATCH] No changes, just fix a slightly misleading comment in wxMSW focus code. DefWindowProc() never preserves the focused window actually, whether we use WM_NEXTDLGCTL (which is only handled by DefDlgProc() anyhow) or not. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@78360 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/msw/toplevel.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/msw/toplevel.cpp b/src/msw/toplevel.cpp index afb0b8cb69..58a9c1c675 100644 --- a/src/msw/toplevel.cpp +++ b/src/msw/toplevel.cpp @@ -371,10 +371,9 @@ WXLRESULT wxTopLevelWindowMSW::MSWWindowProc(WXUINT message, WXWPARAM wParam, WX // using the bitwise AND operator. unsigned id = wParam & 0xfff0; - // Preserve the focus when minimizing/restoring the window: we - // need to do it manually as DefWindowProc() doesn't appear to - // do this for us for some reason (perhaps because we don't use - // WM_NEXTDLGCTL for setting focus?). Moreover, our code in + // Preserve the focus when minimizing/restoring the window: + // surprisingly, DefWindowProc() doesn't do it automatically + // and so we need to it ourselves. Moreover, our code in // OnActivate() doesn't work in this case as we receive the // deactivation event too late when the window is being // minimized and the focus is already NULL by then. Similarly,