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

Unified Diff: ui/views/focus/focus_manager.cc

Issue 727583002: Regression: Search+Key pops up app launcher (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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
« ui/base/accelerators/accelerator_history.h ('K') | « ui/base/ui_base.gyp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/focus/focus_manager.cc
diff --git a/ui/views/focus/focus_manager.cc b/ui/views/focus/focus_manager.cc
index 8dec8eaafb6097ed30e21e371689164b24dc7bb0..7de6513fc6e22d960903984244fa95f6d874115d 100644
--- a/ui/views/focus/focus_manager.cc
+++ b/ui/views/focus/focus_manager.cc
@@ -11,6 +11,7 @@
#include "base/logging.h"
#include "build/build_config.h"
#include "ui/base/accelerators/accelerator.h"
+#include "ui/base/accelerators/accelerator_history.h"
#include "ui/base/ime/input_method.h"
#include "ui/base/ime/text_input_client.h"
#include "ui/base/ime/text_input_focus_manager.h"
@@ -59,20 +60,8 @@ bool FocusManager::OnKeyEvent(const ui::KeyEvent& event) {
if (shortcut_handling_suspended())
return true;
- int modifiers = ui::EF_NONE;
- if (event.IsShiftDown())
- modifiers |= ui::EF_SHIFT_DOWN;
- if (event.IsControlDown())
- modifiers |= ui::EF_CONTROL_DOWN;
- if (event.IsAltDown())
- modifiers |= ui::EF_ALT_DOWN;
-#if defined(OS_MACOSX) || defined(OS_CHROMEOS)
- if (event.IsCommandDown())
- modifiers |= ui::EF_COMMAND_DOWN;
-#endif
- ui::Accelerator accelerator(event.key_code(), modifiers);
- accelerator.set_type(event.type());
- accelerator.set_is_repeat(event.IsRepeat());
+ ui::Accelerator accelerator(ui::AcceleratorHistory::GetInstance()->
+ GetCurrentAccelerator());
Jun Mukai 2014/11/17 17:39:20 Can we revert this? Is there any specific reason
afakhry 2014/11/17 23:10:18 Done.
if (event.type() == ui::ET_KEY_PRESSED) {
// If the focused view wants to process the key event as is, let it be.
« ui/base/accelerators/accelerator_history.h ('K') | « ui/base/ui_base.gyp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698