views: Fix showing menu bar when pressing Alt for a long time

This commit is contained in:
Cheng Zhao 2014-11-07 15:20:16 +08:00 committed by Frank Hale
parent b92d5071fa
commit 716037544a

View file

@ -719,8 +719,7 @@ void NativeWindowViews::HandleKeyboardEvent(
return;
// Toggle the menu bar only when a single Alt is released.
if (event.type == blink::WebInputEvent::RawKeyDown && IsAltKey(event) &&
IsAltModifier(event)) {
if (event.type == blink::WebInputEvent::RawKeyDown && IsAltKey(event)) {
// When a single Alt is pressed:
menu_bar_alt_pressed_ = true;
} else if (event.type == blink::WebInputEvent::KeyUp && IsAltKey(event) &&