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

Unified Diff: ui/views/controls/menu/menu_controller.cc

Issue 9224001: Fixes issue with accelerators when a menu is open (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Changes as requested Created 8 years, 11 months 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
« ash/accelerators/accelerator_dispatcher_win.cc ('K') | « ash/ash.gyp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/menu/menu_controller.cc
diff --git a/ui/views/controls/menu/menu_controller.cc b/ui/views/controls/menu/menu_controller.cc
index 4a187cebd6c7fba6a305a86c85e167660d13fa98..60573ee1beebcdbf9380cc1c6dc778efe01d61c4 100644
--- a/ui/views/controls/menu/menu_controller.cc
+++ b/ui/views/controls/menu/menu_controller.cc
@@ -25,6 +25,7 @@
#include "ui/views/widget/widget.h"
#if defined(USE_AURA)
+#include "ash/accelerators/accelerator_dispatcher.h"
#include "ui/aura/root_window.h"
#elif defined(TOOLKIT_USES_GTK)
#include "ui/base/keycodes/keyboard_code_conversion_gtk.h"
@@ -318,7 +319,12 @@ MenuItemView* MenuController::Run(Widget* parent,
MessageLoopForUI* loop = MessageLoopForUI::current();
bool did_allow_task_nesting = loop->NestableTasksAllowed();
loop->SetNestableTasksAllowed(true);
+#if defined(USE_AURA)
+ ash::AcceleratorDispatcher dispatcher(this);
+ loop->RunWithDispatcher(&dispatcher);
+#else
loop->RunWithDispatcher(this);
+#endif
loop->SetNestableTasksAllowed(did_allow_task_nesting);
if (ViewsDelegate::views_delegate)
« ash/accelerators/accelerator_dispatcher_win.cc ('K') | « ash/ash.gyp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698