Commit 78103a6b authored by Mike Frysinger's avatar Mike Frysinger Committed by Commit Bot

omnibox: allow command-enter on all platforms

On macOS, Command-Enter is available via the ⌘ key, but Windows & Linux
can trigger this equivalent functionality via the Windows ⊞ key, and
Chrome OS has a search πŸ” key.  Support passing this disposition in the
omnibox on all platforms.

Bug: None
Change-Id: I9a477678abbb8b369bee0eb9352f769d6b5d8fd8
Reviewed-on: https://chromium-review.googlesource.com/1132102Reviewed-by: default avatarElly Fong-Jones <ellyjones@chromium.org>
Reviewed-by: default avatarJustin Donnelly <jdonnelly@chromium.org>
Commit-Queue: Mike Frysinger <vapier@chromium.org>
Cr-Commit-Position: refs/heads/master@{#573949}
parent a3a1f12b
...@@ -1179,11 +1179,7 @@ bool OmniboxViewViews::HandleKeyEvent(views::Textfield* textfield, ...@@ -1179,11 +1179,7 @@ bool OmniboxViewViews::HandleKeyEvent(views::Textfield* textfield,
const bool shift = event.IsShiftDown(); const bool shift = event.IsShiftDown();
const bool control = event.IsControlDown(); const bool control = event.IsControlDown();
const bool alt = event.IsAltDown() || event.IsAltGrDown(); const bool alt = event.IsAltDown() || event.IsAltGrDown();
#if defined(OS_MACOSX)
const bool command = event.IsCommandDown(); const bool command = event.IsCommandDown();
#else
const bool command = false;
#endif
switch (event.key_code()) { switch (event.key_code()) {
case ui::VKEY_RETURN: case ui::VKEY_RETURN:
if (model()->popup_model()->SelectedLineHasTabMatch() && if (model()->popup_model()->SelectedLineHasTabMatch() &&
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment