| Index: ui/base/win/events_win.cc
|
| diff --git a/ui/base/win/events_win.cc b/ui/base/win/events_win.cc
|
| index a014ce06280590dfc3a182a1d00e697a5a08e0cf..3afddc293daf1d04851a62058b83f96778feb3df 100644
|
| --- a/ui/base/win/events_win.cc
|
| +++ b/ui/base/win/events_win.cc
|
| @@ -8,6 +8,7 @@
|
|
|
| #include "base/logging.h"
|
| #include "base/time.h"
|
| +#include "base/win/win_util.h"
|
| #include "ui/base/keycodes/keyboard_code_conversion_win.h"
|
| #include "ui/gfx/point.h"
|
|
|
| @@ -84,9 +85,9 @@ bool IsKeyEvent(const base::NativeEvent& native_event) {
|
| // Checks the current global state and the state sent by client mouse messages.
|
| int KeyStateFlagsFromNative(const base::NativeEvent& native_event) {
|
| int flags = 0;
|
| - flags |= (GetKeyState(VK_MENU) & 0x80) ? ui::EF_ALT_DOWN : 0;
|
| - flags |= (GetKeyState(VK_SHIFT) & 0x80) ? ui::EF_SHIFT_DOWN : 0;
|
| - flags |= (GetKeyState(VK_CONTROL) & 0x80) ? ui::EF_CONTROL_DOWN : 0;
|
| + flags |= base::win::IsAltPressed() ? ui::EF_ALT_DOWN : ui::EF_NONE;
|
| + flags |= base::win::IsShiftPressed() ? ui::EF_SHIFT_DOWN : ui::EF_NONE;
|
| + flags |= base::win::IsCtrlPressed() ? ui::EF_CONTROL_DOWN : ui::EF_NONE;
|
|
|
| // Check key messages for the extended key flag.
|
| if (IsKeyEvent(native_event))
|
|
|