From 70de23dabb17634940f25d76c03e3ac3b62d58d4 Mon Sep 17 00:00:00 2001 From: Francisco De La Cruz Date: Thu, 25 Apr 2013 05:32:32 +0000 Subject: [PATCH] Fix #29932 Left Shift + Numpad 1,2,3 not Aligning to Active Intermediate Shift+Key messages were resetting modifier flags. --- intern/ghost/intern/GHOST_SystemWin32.cpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/intern/ghost/intern/GHOST_SystemWin32.cpp b/intern/ghost/intern/GHOST_SystemWin32.cpp index b3f2f218778..fb095b5f4be 100644 --- a/intern/ghost/intern/GHOST_SystemWin32.cpp +++ b/intern/ghost/intern/GHOST_SystemWin32.cpp @@ -607,7 +607,17 @@ GHOST_TKey GHOST_SystemWin32::convertKey(GHOST_IWindow *window, short vKey, shor case VK_GR_LESS: key = GHOST_kKeyGrLess; break; case VK_SHIFT: - key = (scanCode == 0x36) ? GHOST_kKeyRightShift : GHOST_kKeyLeftShift; + /* Check single shift presses */ + if (scanCode == 0x36) { + key = GHOST_kKeyRightShift; + } else if (scanCode == 0x2a) { + key = GHOST_kKeyLeftShift; + } else { + /* Must be a combination SHIFT (Left or Right) + a Key + * Ignore this as the next message will contain + * the desired "Key" */ + key = GHOST_kKeyUnknown; + } break; case VK_CONTROL: key = (extend) ? GHOST_kKeyRightControl : GHOST_kKeyLeftControl;