OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CONTENT_COMMON_INPUT_INPUT_EVENT_DISPOSITION_H_ |
| 6 #define CONTENT_COMMON_INPUT_INPUT_EVENT_DISPOSITION_H_ |
| 7 |
| 8 #include <vector> |
| 9 |
| 10 #include "content/common/content_export.h" |
| 11 #include "content/port/common/input_event_ack_state.h" |
| 12 |
| 13 namespace content { |
| 14 |
| 15 // Disposition of input events as they are handled and passed between the |
| 16 // browser and renderer. |
| 17 enum InputEventDisposition { |
| 18 INPUT_EVENT_UNHANDLED, |
| 19 INPUT_EVENT_COULD_NOT_DELIVER, |
| 20 |
| 21 INPUT_EVENT_IMPL_THREAD_CONSUMED, |
| 22 INPUT_EVENT_IMPL_THREAD_BOUNCE_TO_MAIN, |
| 23 INPUT_EVENT_IMPL_THREAD_NO_CONSUMER_EXISTS, |
| 24 |
| 25 INPUT_EVENT_MAIN_THREAD_CONSUMED, |
| 26 INPUT_EVENT_MAIN_THREAD_PREVENT_DEFAULTED, |
| 27 INPUT_EVENT_MAIN_THREAD_NOT_PREVENT_DEFAULTED, |
| 28 INPUT_EVENT_MAIN_THREAD_NO_CONSUMER_EXISTS, |
| 29 |
| 30 INPUT_EVENT_DISPOSITION_MAX = INPUT_EVENT_MAIN_THREAD_NO_CONSUMER_EXISTS |
| 31 }; |
| 32 typedef std::vector<InputEventDisposition> InputEventDispositions; |
| 33 |
| 34 InputEventDisposition CONTENT_EXPORT ToDisposition(InputEventAckState ack, |
| 35 bool main_thread, |
| 36 bool prevent_default); |
| 37 InputEventAckState CONTENT_EXPORT ToAckState(InputEventDisposition disposition); |
| 38 |
| 39 } // namespace content |
| 40 |
| 41 #endif // CONTENT_COMMON_INPUT_INPUT_EVENT_DISPOSITION_H_ |
OLD | NEW |