Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1866)

Unified Diff: content/browser/renderer_host/input/web_input_event_builders_win.cc

Issue 142253002: Added checking for higher bit being set in GetAsyncKeyState return value. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/input/web_input_event_builders_win.cc
diff --git a/content/browser/renderer_host/input/web_input_event_builders_win.cc b/content/browser/renderer_host/input/web_input_event_builders_win.cc
index 8c63e44db0905edbeed2947b30727154d82831e4..2541bcae70fa2119e50f072667213784cba945bb 100644
--- a/content/browser/renderer_host/input/web_input_event_builders_win.cc
+++ b/content/browser/renderer_host/input/web_input_event_builders_win.cc
@@ -339,9 +339,9 @@ WebMouseWheelEventBuilder::Build(HWND hwnd, UINT message,
// for key state since we are synthesizing the input event.
get_key_state_func = GetAsyncKeyState;
key_state = 0;
- if (get_key_state_func(VK_SHIFT))
+ if (get_key_state_func(VK_SHIFT) & 0x8000)
key_state |= MK_SHIFT;
- if (get_key_state_func(VK_CONTROL))
+ if (get_key_state_func(VK_CONTROL) & 0x8000)
key_state |= MK_CONTROL;
// NOTE: There doesn't seem to be a way to query the mouse button state
// in this case.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698