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

Unified Diff: content/common/input/input_event_disposition.h

Issue 19624005: Add InputEvent and EventPacket types for batched input delivery (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Cleanup Created 7 years, 4 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: content/common/input/input_event_disposition.h
diff --git a/content/common/input/input_event_disposition.h b/content/common/input/input_event_disposition.h
new file mode 100644
index 0000000000000000000000000000000000000000..ed1a7d93e5273c15912831cfe80fc4cb33ee382e
--- /dev/null
+++ b/content/common/input/input_event_disposition.h
@@ -0,0 +1,36 @@
+// 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.
+
+#ifndef CONTENT_COMMON_INPUT_INPUT_EVENT_DISPOSITION_H_
+#define CONTENT_COMMON_INPUT_INPUT_EVENT_DISPOSITION_H_
+
+#include "content/common/content_export.h"
+#include "content/port/common/input_event_ack_state.h"
+
+namespace content {
+
+// Disposition of input events as they are handled and passed between the
+// browser and renderer.
+enum InputEventDisposition {
+ INPUT_EVENT_UNHANDLED,
+ INPUT_EVENT_COULD_NOT_DELIVER,
+
+ INPUT_EVENT_IMPL_THREAD_CONSUMED,
+ INPUT_EVENT_IMPL_THREAD_BOUNCE_TO_MAIN,
+ INPUT_EVENT_IMPL_THREAD_NO_CONSUMER_EXISTS,
+
+ INPUT_EVENT_MAIN_THREAD_CONSUMED,
+ INPUT_EVENT_MAIN_THREAD_PREVENT_DEFAULTED,
+ INPUT_EVENT_MAIN_THREAD_NOT_PREVENT_DEFAULTED,
+ INPUT_EVENT_MAIN_THREAD_NO_CONSUMER_EXISTS
+};
+
+InputEventDisposition CONTENT_EXPORT ToDisposition(InputEventAckState ack,
+ bool main_thread,
+ bool prevent_default);
+InputEventAckState CONTENT_EXPORT ToAckState(InputEventDisposition disposition);
+
+} // namespace content
+
+#endif // CONTENT_COMMON_INPUT_INPUT_EVENT_DISPOSITION_H_

Powered by Google App Engine
This is Rietveld 408576698