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

Unified Diff: base/message_pump_glib_x_dispatch.h

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 | « base/message_pump_glib_x.cc ('k') | chrome/browser/chromeos/views/native_menu_domui.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/message_pump_glib_x_dispatch.h
diff --git a/base/message_pump_glib_x_dispatch.h b/base/message_pump_glib_x_dispatch.h
new file mode 100644
index 0000000000000000000000000000000000000000..95364a2ad42567ee042624dbb441ccdc43410416
--- /dev/null
+++ b/base/message_pump_glib_x_dispatch.h
@@ -0,0 +1,28 @@
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef BASE_MESSAGE_PUMP_GLIB_X_DISPATCH_H
+#define BASE_MESSAGE_PUMP_GLIB_X_DISPATCH_H
+
+#include "base/message_pump.h"
+#include "base/message_pump_glib.h"
+
+typedef union _XEvent XEvent;
+
+namespace base {
+
+// The message pump used for TOUCH_UI on linux is MessagePumpGlibX, which can
+// dispatch both GdkEvents* and XEvents* captured directly from X.
+// MessagePumpForUI::Dispatcher provides the mechanism for dispatching
+// GdkEvents. This class provides additional mechanism for dispatching XEvents.
+class MessagePumpGlibXDispatcher : public MessagePumpForUI::Dispatcher {
+ public:
+ // Dispatches the event. If true is returned processing continues as
+ // normal. If false is returned, the nested loop exits immediately.
+ virtual bool Dispatch(XEvent* xevent) = 0;
+};
+
+} // namespace base
+
+#endif // BASE_MESSAGE_PUMP_GLIB_X_DISPATCH_H
« no previous file with comments | « base/message_pump_glib_x.cc ('k') | chrome/browser/chromeos/views/native_menu_domui.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698