From 67be35304088c916867472ff05114a11d2750881 Mon Sep 17 00:00:00 2001 From: Dmitry Timoshkov Date: Mon, 27 Oct 2008 19:14:28 +0800 Subject: [PATCH] kernel32: Don't ignore extended keys. --- dlls/kernel32/console.c | 3 +-- dlls/kernel32/editline.c | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/dlls/kernel32/console.c b/dlls/kernel32/console.c index a985060685..edaafbc6ae 100644 --- a/dlls/kernel32/console.c +++ b/dlls/kernel32/console.c @@ -1377,8 +1377,7 @@ BOOL WINAPI ReadConsoleW(HANDLE hConsoleInput, LPVOID lpBuffer, { if (read_console_input(hConsoleInput, &ir, timeout) != rci_gotone) break; if (ir.EventType == KEY_EVENT && ir.Event.KeyEvent.bKeyDown && - ir.Event.KeyEvent.uChar.UnicodeChar && - !(ir.Event.KeyEvent.dwControlKeyState & ENHANCED_KEY)) + ir.Event.KeyEvent.uChar.UnicodeChar) { xbuf[charsread++] = ir.Event.KeyEvent.uChar.UnicodeChar; timeout = 0; diff --git a/dlls/kernel32/editline.c b/dlls/kernel32/editline.c index 0a663cfe07..6fab049a72 100644 --- a/dlls/kernel32/editline.c +++ b/dlls/kernel32/editline.c @@ -818,7 +818,7 @@ WCHAR* CONSOLE_Readline(HANDLE hConsoleIn) /* EPP WCEL_Dump(&ctx, "before func"); */ ofs = ctx.ofs; /* mask out some bits which don't interest us */ - ks = ir.Event.KeyEvent.dwControlKeyState & ~(NUMLOCK_ON|SCROLLLOCK_ON|CAPSLOCK_ON); + ks = ir.Event.KeyEvent.dwControlKeyState & ~(NUMLOCK_ON|SCROLLLOCK_ON|CAPSLOCK_ON|ENHANCED_KEY); func = NULL; for (km = (use_emacs) ? EmacsKeyMap : Win32KeyMap; km->entries != NULL; km++) @@ -845,7 +845,7 @@ WCHAR* CONSOLE_Readline(HANDLE hConsoleIn) if (func) (func)(&ctx); - else if (!(ir.Event.KeyEvent.dwControlKeyState & (ENHANCED_KEY|LEFT_ALT_PRESSED))) + else if (!(ir.Event.KeyEvent.dwControlKeyState & LEFT_ALT_PRESSED)) WCEL_InsertChar(&ctx, ir.Event.KeyEvent.uChar.UnicodeChar); else TRACE("Dropped event\n");