From cf4b4f70560af333f13ae7f79ad9badccded555e Mon Sep 17 00:00:00 2001 From: Lei Zhang Date: Wed, 23 Apr 2008 23:57:26 -0700 Subject: [PATCH] winex11.drv: control + enter should generate '\n' instead of '\r'. --- dlls/winex11.drv/keyboard.c | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/dlls/winex11.drv/keyboard.c b/dlls/winex11.drv/keyboard.c index 5d48ce7..40c3e55 100644 --- a/dlls/winex11.drv/keyboard.c +++ b/dlls/winex11.drv/keyboard.c @@ -2566,6 +2566,12 @@ INT X11DRV_ToUnicodeEx(UINT virtKey, UINT scanCode, LPBYTE lpKeyState, lpChar[0] = 0; ret = 0; } + else if((lpKeyState[VK_CONTROL] & 0x80) /* Control is pressed */ + && (keysym == XK_Return || keysym == XK_KP_Enter)) + { + lpChar[0] = '\n'; + ret = 1; + } /* Hack to detect an XLookupString hard-coded to Latin1 */ if (ret == 1 && keysym >= 0x00a0 && keysym <= 0x00ff && (BYTE)lpChar[0] == keysym) -- 1.5.2.2