Upstream version 9.38.204.0
[platform/framework/web/crosswalk.git] / src / ozone / ui / public / messages.h
1 // Copyright 2013 Intel Corporation. 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 // Multiply-included message file, hence no include guard here.
6
7 #include <string>
8
9 #include "base/basictypes.h"
10 #include "base/strings/string16.h"
11 #include "ipc/ipc_message_macros.h"
12 #include "ipc/ipc_message_utils.h"
13 #include "ipc/ipc_param_traits.h"
14 #include "ipc/param_traits_macros.h"
15 #include "ozone/ui/events/window_constants.h"
16 #include "ui/events/event_constants.h"
17 #include "ui/gfx/geometry/rect.h"
18 #include "ui/gfx/ipc/gfx_param_traits.h"
19
20
21 #define IPC_MESSAGE_START LastIPCMsgStart
22
23 IPC_ENUM_TRAITS_MAX_VALUE(ui::EventFlags,
24                           ui::EF_ALTGR_DOWN)
25 IPC_ENUM_TRAITS_MAX_VALUE(ui::EventType,
26                           ui::ET_LAST)
27 IPC_ENUM_TRAITS_MAX_VALUE(ui::WidgetState,
28                           ui::DESTROYED)
29 IPC_ENUM_TRAITS_MAX_VALUE(ui::WidgetType,
30                           ui::POPUP)
31
32 IPC_MESSAGE_CONTROL2(WaylandInput_MotionNotify,  // NOLINT(readability/fn_size)
33                      float /*x*/,
34                      float /*y*/)
35
36 IPC_MESSAGE_CONTROL5(WaylandInput_ButtonNotify,  // NOLINT(readability/fn_size)
37                      unsigned /*handle*/,
38                      ui::EventType /*type*/,
39                      ui::EventFlags /*flags*/,
40                      float /*x*/,
41                      float /*y*/)
42
43 IPC_MESSAGE_CONTROL5(WaylandInput_TouchNotify,  // NOLINT(readability/fn_size)
44                      ui::EventType /*type*/,
45                      float /*x*/,
46                      float /*y*/,
47                      int32_t /*touch_id*/,
48                      uint32_t /*time_stamp*/)
49
50 IPC_MESSAGE_CONTROL4(WaylandInput_AxisNotify,  // NOLINT(readability/fn_size)
51                      float /*x*/,
52                      float /*y*/,
53                      int /*x_offset*/,
54                      int /*y_offset*/)
55
56 IPC_MESSAGE_CONTROL3(WaylandInput_PointerEnter,  // NOLINT(readability/fn_size)
57                      unsigned /*handle*/,
58                      float /*x*/,
59                      float /*y*/)
60
61 IPC_MESSAGE_CONTROL3(WaylandInput_PointerLeave,  // NOLINT(readability/fn_size)
62                      unsigned /*handle*/,
63                      float /*x*/,
64                      float /*y*/)
65
66 IPC_MESSAGE_CONTROL3(WaylandInput_KeyNotify,  // NOLINT(readability/fn_size)
67                      ui::EventType /*type*/,
68                      unsigned /*code*/,
69                      unsigned /*modifiers*/)
70
71 IPC_MESSAGE_CONTROL2(WaylandInput_OutputSize,  // NOLINT(readability/fn_size)
72                      unsigned /*width*/,
73                      unsigned /*height*/)
74
75 IPC_MESSAGE_CONTROL1(WaylandInput_CloseWidget,  // NOLINT(readability/fn_size)
76                      unsigned /*handle*/)
77
78 IPC_MESSAGE_CONTROL3(WaylandWindow_Resized,  // NOLINT(readability/fn_size)
79                      unsigned /* window handle */,
80                      unsigned /* width */,
81                      unsigned /* height */)
82
83 IPC_MESSAGE_CONTROL1(WaylandWindow_Unminimized,  // NOLINT(readability/fn_size)
84                      unsigned /*handle*/)
85
86 IPC_MESSAGE_CONTROL4(WaylandWindow_State,  // NOLINT(readability/fn_size)
87                      unsigned /* window handle */,
88                      ui::WidgetState /*state*/,
89                      unsigned /*width*/,
90                      unsigned /*height*/)
91
92 IPC_MESSAGE_CONTROL5(WaylandWindow_Attributes,  // NOLINT(readability/fn_size)
93                      unsigned /* window handle */,
94                      unsigned /* window parent */,
95                      unsigned /* x */,
96                      unsigned /* y */,
97                      ui::WidgetType /* window type */)
98
99 IPC_MESSAGE_CONTROL2(WaylandWindow_Title,  // NOLINT(readability/fn_size)
100                      unsigned /* window handle */,
101                      base::string16 /* window title */)
102
103 IPC_MESSAGE_CONTROL1(WaylandWindow_Cursor,  // NOLINT(readability/fn_size)
104                      int /* cursor type */)
105
106 IPC_MESSAGE_CONTROL0(WaylandWindow_ImeReset)  // NOLINT(readability/fn_size)
107
108 IPC_MESSAGE_CONTROL1(WaylandWindow_ImeCaretBoundsChanged, // NOLINT(readability/
109                      gfx::Rect /* ImeCaretBoundsChanged */)  //      fn_size)
110
111 IPC_MESSAGE_CONTROL0(WaylandWindow_ShowInputPanel)  // NOLINT(readability/
112                                                    //         fn_size)
113
114 IPC_MESSAGE_CONTROL0(WaylandWindow_HideInputPanel)  // NOLINT(readability/
115                                                    //         fn_size)
116
117 IPC_MESSAGE_CONTROL2(WaylandInput_Commit,  // NOLINT(readability/fn_size)
118                      unsigned,
119                      std::string)
120
121 IPC_MESSAGE_CONTROL3(WaylandInput_PreeditChanged, // NOLINT(readability/
122                      unsigned,                    //        fn_size)
123                      std::string, std::string)
124
125 IPC_MESSAGE_CONTROL0(WaylandInput_PreeditEnd)  // NOLINT(readability/fn_size)
126
127 IPC_MESSAGE_CONTROL0(WaylandInput_PreeditStart)  // NOLINT(readability/fn_size)