From: Vadim Zeitlin Date: Sun, 26 May 2002 12:04:12 +0000 (+0000) Subject: set the focus to the first control in the dialog when it is shwon X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/dea077b16481f0f8711101c6930281f1c4a4f744 set the focus to the first control in the dialog when it is shwon git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15673 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/msw/toplevel.cpp b/src/msw/toplevel.cpp index 91804dda88..14caef0e56 100644 --- a/src/msw/toplevel.cpp +++ b/src/msw/toplevel.cpp @@ -88,9 +88,9 @@ wxDlgProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) switch ( message ) { case WM_INITDIALOG: - // for this message, returning TRUE tells system to set focus to the - // first control in the dialog box - return TRUE; + // for this message, returning TRUE tells system to set focus to + // the first control in the dialog box, but as we set the focus + // ourselves, we return FALSE from here as well, so fall through default: // for all the other ones, FALSE means that we didn't process the