OLD | NEW |
| (Empty) |
1 // Copyright (c) 2016 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 | |
6 #include "components/mus/common/mus_common_export.h" | |
7 #include "ipc/ipc_message_utils.h" | |
8 #include "ipc/param_traits_macros.h" | |
9 #include "ui/events/event.h" | |
10 #include "ui/events/event_constants.h" | |
11 | |
12 #undef IPC_MESSAGE_EXPORT | |
13 #define IPC_MESSAGE_EXPORT MUS_COMMON_EXPORT | |
14 | |
15 IPC_ENUM_TRAITS_MIN_MAX_VALUE(ui::EventType, | |
16 ui::EventType::ET_UNKNOWN, | |
17 ui::EventType::ET_LAST) | |
18 | |
19 IPC_ENUM_TRAITS_MIN_MAX_VALUE(ui::EventResult, | |
20 ui::EventResult::ER_UNHANDLED, | |
21 ui::EventResult::ER_DISABLE_SYNC_HANDLING) | |
22 | |
23 IPC_ENUM_TRAITS_MIN_MAX_VALUE(ui::EventPhase, | |
24 ui::EventPhase::EP_PREDISPATCH, | |
25 ui::EventPhase::EP_POSTDISPATCH) | |
26 | |
27 IPC_ENUM_TRAITS_MIN_MAX_VALUE(ui::EventPointerType, | |
28 ui::EventPhase::EP_PREDISPATCH, | |
29 ui::EventPhase::EP_POSTDISPATCH) | |
30 | |
31 IPC_ENUM_TRAITS_MIN_MAX_VALUE(ui::KeyboardCode, | |
32 ui::KeyboardCode::VKEY_UNKNOWN, /* 0x00 */ | |
33 ui::KeyboardCode::VKEY_OEM_CLEAR /* 0xFE */) | |
34 | |
35 IPC_ENUM_TRAITS_MIN_MAX_VALUE(ui::DomCode, 0, 0x0c028c) | |
36 | |
37 IPC_STRUCT_TRAITS_BEGIN(ui::PointerDetails) | |
38 IPC_STRUCT_TRAITS_MEMBER(pointer_type) | |
39 IPC_STRUCT_TRAITS_MEMBER(radius_x) | |
40 IPC_STRUCT_TRAITS_MEMBER(radius_y) | |
41 IPC_STRUCT_TRAITS_MEMBER(force) | |
42 IPC_STRUCT_TRAITS_MEMBER(tilt_x) | |
43 IPC_STRUCT_TRAITS_MEMBER(tilt_y) | |
44 IPC_STRUCT_TRAITS_END() | |
45 | |
46 IPC_STRUCT_TRAITS_BEGIN(ui::LocatedEvent) | |
47 IPC_STRUCT_TRAITS_MEMBER(location_) | |
48 IPC_STRUCT_TRAITS_MEMBER(root_location_) | |
49 IPC_STRUCT_TRAITS_END() | |
50 | |
51 IPC_STRUCT_TRAITS_BEGIN(ui::MouseEvent) | |
52 IPC_STRUCT_TRAITS_PARENT(ui::LocatedEvent) | |
53 IPC_STRUCT_TRAITS_MEMBER(changed_button_flags_) | |
54 IPC_STRUCT_TRAITS_MEMBER(pointer_details_) | |
55 IPC_STRUCT_TRAITS_END() | |
56 | |
57 IPC_STRUCT_TRAITS_BEGIN(ui::MouseWheelEvent) | |
58 IPC_STRUCT_TRAITS_PARENT(ui::MouseEvent) | |
59 IPC_STRUCT_TRAITS_MEMBER(offset_) | |
60 IPC_STRUCT_TRAITS_END() | |
61 | |
62 IPC_STRUCT_TRAITS_BEGIN(ui::TouchEvent) | |
63 IPC_STRUCT_TRAITS_PARENT(ui::LocatedEvent) | |
64 IPC_STRUCT_TRAITS_MEMBER(touch_id_) | |
65 IPC_STRUCT_TRAITS_MEMBER(unique_event_id_) | |
66 IPC_STRUCT_TRAITS_MEMBER(rotation_angle_) | |
67 IPC_STRUCT_TRAITS_MEMBER(may_cause_scrolling_) | |
68 IPC_STRUCT_TRAITS_MEMBER(pointer_details_) | |
69 IPC_STRUCT_TRAITS_END() | |
70 | |
71 IPC_STRUCT_TRAITS_BEGIN(ui::DomKey) | |
72 IPC_STRUCT_TRAITS_MEMBER(value_) | |
73 IPC_STRUCT_TRAITS_END() | |
74 | |
75 IPC_STRUCT_TRAITS_BEGIN(ui::KeyEvent) | |
76 IPC_STRUCT_TRAITS_MEMBER(is_char_) | |
77 IPC_STRUCT_TRAITS_MEMBER(key_code_) | |
78 IPC_STRUCT_TRAITS_MEMBER(code_) | |
79 IPC_STRUCT_TRAITS_MEMBER(key_) | |
80 IPC_STRUCT_TRAITS_END() | |
81 | |
82 IPC_STRUCT_TRAITS_BEGIN(ui::ScrollEvent) | |
83 IPC_STRUCT_TRAITS_PARENT(ui::MouseEvent) | |
84 IPC_STRUCT_TRAITS_MEMBER(x_offset_) | |
85 IPC_STRUCT_TRAITS_MEMBER(y_offset_) | |
86 IPC_STRUCT_TRAITS_MEMBER(x_offset_ordinal_) | |
87 IPC_STRUCT_TRAITS_MEMBER(y_offset_ordinal_) | |
88 IPC_STRUCT_TRAITS_MEMBER(finger_count_) | |
89 IPC_STRUCT_TRAITS_END() | |
90 | |
91 IPC_STRUCT_TRAITS_BEGIN(ui::GestureEventDetails) | |
92 IPC_STRUCT_TRAITS_MEMBER(type_) | |
93 IPC_STRUCT_TRAITS_MEMBER(data_) | |
94 IPC_STRUCT_TRAITS_MEMBER(touch_points_) | |
95 IPC_STRUCT_TRAITS_MEMBER(bounding_box_) | |
96 IPC_STRUCT_TRAITS_END() | |
97 | |
98 IPC_STRUCT_TRAITS_BEGIN(ui::GestureEvent) | |
99 IPC_STRUCT_TRAITS_PARENT(ui::LocatedEvent) | |
100 IPC_STRUCT_TRAITS_MEMBER(details_) | |
101 IPC_STRUCT_TRAITS_END() | |
OLD | NEW |