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

Unified Diff: ui/base/ozone/event_converter_ozone.cc

Issue 16466003: Event handling support for ozone. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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: ui/base/ozone/event_converter_ozone.cc
diff --git a/ui/base/ozone/event_converter_ozone.cc b/ui/base/ozone/event_converter_ozone.cc
new file mode 100644
index 0000000000000000000000000000000000000000..86a7d6f5519c8840af08606523ff500725343d3c
--- /dev/null
+++ b/ui/base/ozone/event_converter_ozone.cc
@@ -0,0 +1,27 @@
+// Copyright (c) 2013 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.
+
+#include "ui/base/ozone/event_converter_ozone.h"
+
+#include "base/bind.h"
+#include "base/message_loop.h"
+#include "base/message_pump_ozone.h"
+#include "ui/base/events/event.h"
+
+namespace {
+
+void DispatchEventHelper(ui::Event* key) {
+ base::MessagePumpOzone::Current()->Dispatch(key);
+}
+
+} // namespace
+
+namespace ui {
+
+void EventConverterOzone::DispatchEvent(ui::Event* event) {
+ base::MessageLoop::current()->PostTask(
+ FROM_HERE, base::Bind(&DispatchEventHelper, base::Owned(event)));
+}
+
+} // namespace ui

Powered by Google App Engine
This is Rietveld 408576698