Use keydown event for accelerator.

This follows the behaivor on OS X, fixed #174.
This commit is contained in:
Cheng Zhao 2014-02-06 19:43:30 +08:00
parent 74a83e3d7c
commit f4a2c12d75

View file

@ -417,7 +417,7 @@ void NativeWindowWin::UpdateDraggableRegions(
void NativeWindowWin::HandleKeyboardEvent(
content::WebContents*,
const content::NativeWebKeyboardEvent& event) {
if (event.type == WebKit::WebInputEvent::KeyUp) {
if (event.type == WebKit::WebInputEvent::RawKeyDown) {
ui::Accelerator accelerator(
static_cast<ui::KeyboardCode>(event.windowsKeyCode),
content::GetModifiersFromNativeWebKeyboardEvent(event));