From ad9f1aec6324595612551f7ac83df24c1a47e227 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Wed, 14 Aug 2002 21:22:43 +0000 Subject: [PATCH] Fixed wxMSW's EVT_CHAR so it conforms to the docs and also what wxGTK does already. IOW, Ctrl-C should result in keycode == 3, not 99. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16512 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/msw/window.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/msw/window.cpp b/src/msw/window.cpp index 36162cb9a9..9dbcec6d34 100644 --- a/src/msw/window.cpp +++ b/src/msw/window.cpp @@ -4303,7 +4303,9 @@ bool wxWindowMSW::HandleChar(WXWPARAM wParam, WXLPARAM lParam, bool isASCII) int id; if ( isASCII ) { - // If 1 -> 26, translate to CTRL plus a letter. + // If 1 -> 26, translate to either special keycode or just set + // ctrlDown. IOW, Ctrl-C should result in keycode == 3 and + // ControlDown() == TRUE. id = wParam; if ( (id > 0) && (id < 27) ) { @@ -4323,7 +4325,7 @@ bool wxWindowMSW::HandleChar(WXWPARAM wParam, WXLPARAM lParam, bool isASCII) default: ctrlDown = TRUE; - id = id + 'a' - 1; + break; } } } -- 2.47.2