diff options
author | David Walter Seikel | 2013-01-13 17:29:19 +1000 |
---|---|---|
committer | David Walter Seikel | 2013-01-13 17:29:19 +1000 |
commit | 07274513e984f0b5544586c74508ccd16e7dcafa (patch) | |
tree | b32ff2a9136fbc1a4a6a0ed1e4d79cde0f5f16d9 /libraries/ecore/src/lib/ecore_wayland/Ecore_Wayland.h | |
parent | Added Irrlicht 1.8, but without all the Windows binaries. (diff) | |
download | SledjHamr-07274513e984f0b5544586c74508ccd16e7dcafa.zip SledjHamr-07274513e984f0b5544586c74508ccd16e7dcafa.tar.gz SledjHamr-07274513e984f0b5544586c74508ccd16e7dcafa.tar.bz2 SledjHamr-07274513e984f0b5544586c74508ccd16e7dcafa.tar.xz |
Remove EFL, since it's been released now.
Diffstat (limited to 'libraries/ecore/src/lib/ecore_wayland/Ecore_Wayland.h')
-rw-r--r-- | libraries/ecore/src/lib/ecore_wayland/Ecore_Wayland.h | 304 |
1 files changed, 0 insertions, 304 deletions
diff --git a/libraries/ecore/src/lib/ecore_wayland/Ecore_Wayland.h b/libraries/ecore/src/lib/ecore_wayland/Ecore_Wayland.h deleted file mode 100644 index 7dab37c..0000000 --- a/libraries/ecore/src/lib/ecore_wayland/Ecore_Wayland.h +++ /dev/null | |||
@@ -1,304 +0,0 @@ | |||
1 | #ifndef _ECORE_WAYLAND_H_ | ||
2 | # define _ECORE_WAYLAND_H_ | ||
3 | |||
4 | # define GL_GLEXT_PROTOTYPES | ||
5 | |||
6 | # include <Eina.h> | ||
7 | # include <wayland-client.h> | ||
8 | # include <wayland-egl.h> // NB: already includes wayland-client.h | ||
9 | # include <EGL/egl.h> | ||
10 | # include <EGL/eglext.h> | ||
11 | |||
12 | # ifdef EAPI | ||
13 | # undef EAPI | ||
14 | # endif | ||
15 | |||
16 | # ifdef __GNUC__ | ||
17 | # if __GNUC__ >= 4 | ||
18 | # define EAPI __attribute__ ((visibility("default"))) | ||
19 | # else | ||
20 | # define EAPI | ||
21 | # endif | ||
22 | # else | ||
23 | # define EAPI | ||
24 | # endif | ||
25 | |||
26 | typedef enum _Ecore_Wl_Window_Type Ecore_Wl_Window_Type; | ||
27 | typedef enum _Ecore_Wl_Window_Buffer_Type Ecore_Wl_Window_Buffer_Type; | ||
28 | |||
29 | typedef struct _Ecore_Wl_Display Ecore_Wl_Display; | ||
30 | typedef struct _Ecore_Wl_Output Ecore_Wl_Output; | ||
31 | typedef struct _Ecore_Wl_Input Ecore_Wl_Input; | ||
32 | # ifndef _ECORE_WAYLAND_WINDOW_PREDEF | ||
33 | typedef struct _Ecore_Wl_Window Ecore_Wl_Window; | ||
34 | # endif | ||
35 | typedef struct _Ecore_Wl_Dnd_Source Ecore_Wl_Dnd_Source; | ||
36 | typedef struct _Ecore_Wl_Dnd_Target Ecore_Wl_Dnd_Target; | ||
37 | |||
38 | typedef struct _Ecore_Wl_Event_Mouse_In Ecore_Wl_Event_Mouse_In; | ||
39 | typedef struct _Ecore_Wl_Event_Mouse_Out Ecore_Wl_Event_Mouse_Out; | ||
40 | typedef struct _Ecore_Wl_Event_Focus_In Ecore_Wl_Event_Focus_In; | ||
41 | typedef struct _Ecore_Wl_Event_Focus_Out Ecore_Wl_Event_Focus_Out; | ||
42 | typedef struct _Ecore_Wl_Event_Window_Configure Ecore_Wl_Event_Window_Configure; | ||
43 | typedef struct _Ecore_Wl_Event_Dnd_Enter Ecore_Wl_Event_Dnd_Enter; | ||
44 | typedef struct _Ecore_Wl_Event_Dnd_Position Ecore_Wl_Event_Dnd_Position; | ||
45 | typedef struct _Ecore_Wl_Event_Dnd_Leave Ecore_Wl_Event_Dnd_Leave; | ||
46 | typedef struct _Ecore_Wl_Event_Dnd_Drop Ecore_Wl_Event_Dnd_Drop; | ||
47 | typedef struct _Ecore_Wl_Event_Interfaces_Bound Ecore_Wl_Event_Interfaces_Bound; | ||
48 | |||
49 | enum _Ecore_Wl_Window_Type | ||
50 | { | ||
51 | ECORE_WL_WINDOW_TYPE_TOPLEVEL, | ||
52 | ECORE_WL_WINDOW_TYPE_FULLSCREEN, | ||
53 | ECORE_WL_WINDOW_TYPE_MAXIMIZED, | ||
54 | ECORE_WL_WINDOW_TYPE_TRANSIENT, | ||
55 | ECORE_WL_WINDOW_TYPE_MENU, | ||
56 | ECORE_WL_WINDOW_TYPE_CUSTOM | ||
57 | }; | ||
58 | |||
59 | enum _Ecore_Wl_Window_Buffer_Type | ||
60 | { | ||
61 | ECORE_WL_WINDOW_BUFFER_TYPE_EGL_WINDOW, | ||
62 | ECORE_WL_WINDOW_BUFFER_TYPE_EGL_IMAGE, | ||
63 | ECORE_WL_WINDOW_BUFFER_TYPE_SHM | ||
64 | }; | ||
65 | |||
66 | struct _Ecore_Wl_Display | ||
67 | { | ||
68 | struct | ||
69 | { | ||
70 | struct wl_display *display; | ||
71 | struct wl_compositor *compositor; | ||
72 | struct wl_shell *shell; | ||
73 | struct wl_shm *shm; | ||
74 | struct wl_data_device_manager *data_device_manager; | ||
75 | } wl; | ||
76 | |||
77 | struct | ||
78 | { | ||
79 | EGLDisplay display; | ||
80 | EGLConfig rgb_config; | ||
81 | EGLConfig argb_config; | ||
82 | EGLContext rgb_context; | ||
83 | EGLContext argb_context; | ||
84 | } egl; | ||
85 | |||
86 | int fd; | ||
87 | unsigned int mask; | ||
88 | Ecore_Fd_Handler *fd_hdl; | ||
89 | |||
90 | struct wl_list inputs; | ||
91 | struct wl_list outputs; | ||
92 | |||
93 | struct xkb_desc *xkb; | ||
94 | |||
95 | Ecore_Wl_Output *output; | ||
96 | |||
97 | PFNEGLCREATEIMAGEKHRPROC create_image; | ||
98 | PFNEGLDESTROYIMAGEKHRPROC destroy_image; | ||
99 | |||
100 | void (*output_configure)(Ecore_Wl_Output *output, void *data); | ||
101 | void *data; | ||
102 | }; | ||
103 | |||
104 | struct _Ecore_Wl_Output | ||
105 | { | ||
106 | Ecore_Wl_Display *display; | ||
107 | struct wl_output *output; | ||
108 | Eina_Rectangle allocation; | ||
109 | struct wl_list link; | ||
110 | |||
111 | void (*destroy) (Ecore_Wl_Output *output, void *data); | ||
112 | void *data; | ||
113 | }; | ||
114 | |||
115 | struct _Ecore_Wl_Input | ||
116 | { | ||
117 | Ecore_Wl_Display *display; | ||
118 | struct wl_input_device *input_device; | ||
119 | struct wl_data_device *data_device; | ||
120 | |||
121 | Ecore_Wl_Window *pointer_focus; | ||
122 | Ecore_Wl_Window *keyboard_focus; | ||
123 | |||
124 | unsigned int button; | ||
125 | unsigned int timestamp; | ||
126 | unsigned int modifiers; | ||
127 | int sx, sy; | ||
128 | |||
129 | struct wl_list link; | ||
130 | |||
131 | /* TODO: grab */ | ||
132 | unsigned int grab_button; | ||
133 | |||
134 | Ecore_Wl_Dnd_Source *drag_source; | ||
135 | Ecore_Wl_Dnd_Source *selection_source; | ||
136 | }; | ||
137 | |||
138 | struct _Ecore_Wl_Window | ||
139 | { | ||
140 | Ecore_Wl_Display *display; | ||
141 | Ecore_Wl_Window *parent; | ||
142 | |||
143 | struct wl_surface *surface; | ||
144 | struct wl_shell_surface *shell_surface; | ||
145 | |||
146 | int id; | ||
147 | int x, y; | ||
148 | int edges; | ||
149 | |||
150 | Eina_Rectangle allocation, pending_allocation; | ||
151 | Eina_Rectangle saved_allocation, server_allocation; | ||
152 | |||
153 | /* Eina_Bool redraw_scheduled : 1; */ | ||
154 | /* Eina_Bool resize_scheduled : 1; */ | ||
155 | Eina_Bool transparent : 1; | ||
156 | |||
157 | Ecore_Wl_Window_Type type; | ||
158 | Ecore_Wl_Window_Buffer_Type buffer_type; | ||
159 | |||
160 | Ecore_Wl_Input *pointer_device; | ||
161 | Ecore_Wl_Input *keyboard_device; | ||
162 | |||
163 | void *data; | ||
164 | }; | ||
165 | |||
166 | struct _Ecore_Wl_Event_Mouse_In | ||
167 | { | ||
168 | int modifiers; | ||
169 | int x, y; | ||
170 | struct | ||
171 | { | ||
172 | int x, y; | ||
173 | } root; | ||
174 | unsigned int win; | ||
175 | unsigned int event_win; | ||
176 | unsigned int root_win; | ||
177 | unsigned int timestamp; | ||
178 | }; | ||
179 | |||
180 | struct _Ecore_Wl_Event_Mouse_Out | ||
181 | { | ||
182 | int modifiers; | ||
183 | int x, y; | ||
184 | struct | ||
185 | { | ||
186 | int x, y; | ||
187 | } root; | ||
188 | unsigned int win; | ||
189 | unsigned int event_win; | ||
190 | unsigned int root_win; | ||
191 | unsigned int timestamp; | ||
192 | }; | ||
193 | |||
194 | struct _Ecore_Wl_Event_Focus_In | ||
195 | { | ||
196 | unsigned int win; | ||
197 | unsigned int timestamp; | ||
198 | }; | ||
199 | |||
200 | struct _Ecore_Wl_Event_Focus_Out | ||
201 | { | ||
202 | unsigned int win; | ||
203 | unsigned int timestamp; | ||
204 | }; | ||
205 | |||
206 | struct _Ecore_Wl_Event_Window_Configure | ||
207 | { | ||
208 | unsigned int win; | ||
209 | unsigned int event_win; | ||
210 | int x, y, w, h; | ||
211 | unsigned int timestamp; | ||
212 | }; | ||
213 | |||
214 | struct _Ecore_Wl_Event_Dnd_Enter | ||
215 | { | ||
216 | unsigned int win, source; | ||
217 | char **types; | ||
218 | int num_types; | ||
219 | struct | ||
220 | { | ||
221 | int x, y; | ||
222 | } position; | ||
223 | }; | ||
224 | |||
225 | struct _Ecore_Wl_Event_Dnd_Position | ||
226 | { | ||
227 | unsigned int win, source; | ||
228 | struct | ||
229 | { | ||
230 | int x, y; | ||
231 | } position; | ||
232 | }; | ||
233 | |||
234 | struct _Ecore_Wl_Event_Dnd_Leave | ||
235 | { | ||
236 | unsigned int win, source; | ||
237 | }; | ||
238 | |||
239 | struct _Ecore_Wl_Event_Dnd_Drop | ||
240 | { | ||
241 | unsigned int win, source; | ||
242 | struct | ||
243 | { | ||
244 | int x, y; | ||
245 | } position; | ||
246 | }; | ||
247 | |||
248 | struct _Ecore_Wl_Event_Interfaces_Bound | ||
249 | { | ||
250 | Eina_Bool compositor : 1; | ||
251 | Eina_Bool shm : 1; | ||
252 | Eina_Bool shell : 1; | ||
253 | }; | ||
254 | |||
255 | /** | ||
256 | * @file | ||
257 | * @brief Ecore functions for dealing with the Wayland window system | ||
258 | * | ||
259 | * Ecore_Wl provides a wrapper and convenience functions for using the | ||
260 | * Wayland window system. Function groups for this part of the library | ||
261 | * include the following: | ||
262 | * | ||
263 | * @li @ref Ecore_Wl_Init_Group | ||
264 | * @li @ref Ecore_Wl_Display_Group | ||
265 | * @li @ref Ecore_Wl_Flush_Group | ||
266 | * @li @ref Ecore_Wl_Window_Group | ||
267 | */ | ||
268 | |||
269 | EAPI extern int ECORE_WL_EVENT_MOUSE_IN; | ||
270 | EAPI extern int ECORE_WL_EVENT_MOUSE_OUT; | ||
271 | EAPI extern int ECORE_WL_EVENT_FOCUS_IN; | ||
272 | EAPI extern int ECORE_WL_EVENT_FOCUS_OUT; | ||
273 | EAPI extern int ECORE_WL_EVENT_WINDOW_CONFIGURE; | ||
274 | EAPI extern int ECORE_WL_EVENT_DND_ENTER; | ||
275 | EAPI extern int ECORE_WL_EVENT_DND_POSITION; | ||
276 | EAPI extern int ECORE_WL_EVENT_DND_LEAVE; | ||
277 | EAPI extern int ECORE_WL_EVENT_DND_DROP; | ||
278 | EAPI extern int ECORE_WL_EVENT_INTERFACES_BOUND; | ||
279 | |||
280 | EAPI int ecore_wl_init(const char *name); | ||
281 | EAPI int ecore_wl_shutdown(void); | ||
282 | EAPI void ecore_wl_flush(void); | ||
283 | EAPI void ecore_wl_sync(void); | ||
284 | EAPI struct wl_shm *ecore_wl_shm_get(void); | ||
285 | EAPI struct wl_display *ecore_wl_display_get(void); | ||
286 | EAPI void ecore_wl_screen_size_get(int *w, int *h); | ||
287 | EAPI void ecore_wl_pointer_xy_get(int *x, int *y); | ||
288 | |||
289 | EAPI Ecore_Wl_Window *ecore_wl_window_new(Ecore_Wl_Window *parent, int x, int y, int w, int h, int buffer_type); | ||
290 | EAPI void ecore_wl_window_free(Ecore_Wl_Window *win); | ||
291 | EAPI void ecore_wl_window_move(Ecore_Wl_Window *win, int x, int y); | ||
292 | EAPI void ecore_wl_window_resize(Ecore_Wl_Window *win, int w, int h, int location); | ||
293 | EAPI void ecore_wl_window_damage(Ecore_Wl_Window *win, int x, int y, int w, int h); | ||
294 | EAPI void ecore_wl_window_buffer_attach(Ecore_Wl_Window *win, struct wl_buffer *buffer, int x, int y); | ||
295 | EAPI void ecore_wl_window_show(Ecore_Wl_Window *win); | ||
296 | EAPI void ecore_wl_window_hide(Ecore_Wl_Window *win); | ||
297 | EAPI void ecore_wl_window_raise(Ecore_Wl_Window *win); | ||
298 | EAPI void ecore_wl_window_maximized_set(Ecore_Wl_Window *win, Eina_Bool maximized); | ||
299 | EAPI void ecore_wl_window_fullscreen_set(Ecore_Wl_Window *win, Eina_Bool fullscreen); | ||
300 | EAPI void ecore_wl_window_update_size(Ecore_Wl_Window *win, int w, int h); | ||
301 | EAPI struct wl_surface *ecore_wl_window_surface_get(Ecore_Wl_Window *win); | ||
302 | EAPI Ecore_Wl_Window *ecore_wl_window_find(unsigned int id); | ||
303 | |||
304 | #endif | ||