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

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

Issue 3801011: touchui: Directly process key and mouse events. (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: nit Created 10 years, 2 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
« no previous file with comments | « views/controls/menu/menu_controller.h ('k') | views/controls/menu/native_menu_gtk.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/controls/menu/menu_controller.cc
diff --git a/views/controls/menu/menu_controller.cc b/views/controls/menu/menu_controller.cc
index affddebd5efcc91adb946dd080f44c99dec46948..e0701a2cb9a9cf8d3a43c5595dbbe36ac2304254 100644
--- a/views/controls/menu/menu_controller.cc
+++ b/views/controls/menu/menu_controller.cc
@@ -25,6 +25,10 @@
#include "app/keyboard_code_conversion_gtk.h"
#endif
+#if defined(TOUCH_UI)
+#include "views/focus/accelerator_handler.h"
+#endif
+
using base::Time;
using base::TimeDelta;
@@ -848,12 +852,19 @@ bool MenuController::Dispatch(GdkEvent* event) {
break;
}
- // We don not want Gtk to handle keyboard events, otherwise if they get
+ // We don't want Gtk to handle keyboard events, otherwise if they get
// handled by Gtk, unexpected behavior may occur. For example Tab key
// may cause unexpected focus traversing.
gtk_main_do_event(event);
return exit_type_ == EXIT_NONE;
}
+
+#if defined(TOUCH_UI)
+bool MenuController::Dispatch(XEvent* xev) {
+ return DispatchXEvent(xev);
+}
+#endif
+
#endif
bool MenuController::OnKeyDown(int key_code
« no previous file with comments | « views/controls/menu/menu_controller.h ('k') | views/controls/menu/native_menu_gtk.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698