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

Unified Diff: views/focus/accelerator_handler_touch.cc

Issue 7250001: Refactor the glib message-pump, and use it as the base for a gtk message pump and an X message pump. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 9 years, 6 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
Index: views/focus/accelerator_handler_touch.cc
diff --git a/views/focus/accelerator_handler_touch.cc b/views/focus/accelerator_handler_touch.cc
index 3ffbd6a3ca7994e4afe154b0fc3bb16064b203f7..bbd517216afa04f08c4bde8060788a207cc14dec 100644
--- a/views/focus/accelerator_handler_touch.cc
+++ b/views/focus/accelerator_handler_touch.cc
@@ -177,16 +177,18 @@ void SetTouchDeviceList(std::vector<unsigned int>& devices) {
AcceleratorHandler::AcceleratorHandler() {}
+#if defined(TOUCH_UI)
+base::MessagePumpDispatcher::DispatchStatus
+ AcceleratorHandler::DispatchX(XEvent* xev) {
+ return DispatchXEvent(xev) ?
+ base::MessagePumpDispatcher::EVENT_PROCESSED :
+ base::MessagePumpDispatcher::EVENT_IGNORED;
+}
+#else
bool AcceleratorHandler::Dispatch(GdkEvent* event) {
gtk_main_do_event(event);
return true;
}
-
-base::MessagePumpGlibXDispatcher::DispatchStatus
- AcceleratorHandler::DispatchX(XEvent* xev) {
- return DispatchXEvent(xev) ?
- base::MessagePumpGlibXDispatcher::EVENT_PROCESSED :
- base::MessagePumpGlibXDispatcher::EVENT_IGNORED;
-}
+#endif
} // namespace views

Powered by Google App Engine
This is Rietveld 408576698