Debian Codegraph @

wayland/qtwayland-dev/5.11.3/QtWaylandClient/private/wayland-surface-extension-client-protocol.h

raw symbols SCIP
1 /* Generated by wayland-scanner 1.16.0 */
2
3 #ifndef SURFACE_EXTENSION_CLIENT_PROTOCOL_H
4 #define SURFACE_EXTENSION_CLIENT_PROTOCOL_H
5
6 #include <stdint.h>
7 #include <stddef.h>
8 #include "wayland-client.h"
9
10 #ifdef __cplusplus
11 extern "C" {
12 #endif
13
14 /**
15 * @page page_surface_extension The surface_extension protocol
16 * @section page_ifaces_surface_extension Interfaces
17 * - @subpage page_iface_qt_surface_extension -
18 * - @subpage page_iface_qt_extended_surface -
19 * @section page_copyright_surface_extension Copyright
20 * <pre>
21 *
22 * Copyright (C) 2015 The Qt Company Ltd.
23 * Contact: http://www.qt.io/licensing/
24 *
25 * This file is part of the plugins of the Qt Toolkit.
26 *
27 * $QT_BEGIN_LICENSE:BSD$
28 * You may use this file under the terms of the BSD license as follows:
29 *
30 * "Redistribution and use in source and binary forms, with or without
31 * modification, are permitted provided that the following conditions are
32 * met:
33 * * Redistributions of source code must retain the above copyright
34 * notice, this list of conditions and the following disclaimer.
35 * * Redistributions in binary form must reproduce the above copyright
36 * notice, this list of conditions and the following disclaimer in
37 * the documentation and/or other materials provided with the
38 * distribution.
39 * * Neither the name of The Qt Company Ltd nor the names of its
40 * contributors may be used to endorse or promote products derived
41 * from this software without specific prior written permission.
42 *
43 *
44 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
45 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
46 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
47 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
48 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
49 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
50 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
51 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
52 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
53 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
54 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
55 *
56 * $QT_END_LICENSE$
57 * </pre>
58 */
59 struct qt_extended_surface;
60 struct qt_surface_extension;
61 struct wl_surface;
62
63 /**
64 * @page page_iface_qt_surface_extension qt_surface_extension
65 * @section page_iface_qt_surface_extension_api API
66 * See @ref iface_qt_surface_extension.
67 */
68 /**
69 * @defgroup iface_qt_surface_extension The qt_surface_extension interface
70 */
71 extern const struct wl_interface qt_surface_extension_interface;
72 /**
73 * @page page_iface_qt_extended_surface qt_extended_surface
74 * @section page_iface_qt_extended_surface_api API
75 * See @ref iface_qt_extended_surface.
76 */
77 /**
78 * @defgroup iface_qt_extended_surface The qt_extended_surface interface
79 */
80 extern const struct wl_interface qt_extended_surface_interface;
81
82 #define QT_SURFACE_EXTENSION_GET_EXTENDED_SURFACE 0
83
84
85 /**
86 * @ingroup iface_qt_surface_extension
87 */
88 #define QT_SURFACE_EXTENSION_GET_EXTENDED_SURFACE_SINCE_VERSION 1
89
90 /** @ingroup iface_qt_surface_extension */
91 static inline void
92 qt_surface_extension_set_user_data(struct qt_surface_extension *qt_surface_extension, void *user_data)
93 {
94 wl_proxy_set_user_data((struct wl_proxy *) qt_surface_extension, user_data);
95 }
96
97 /** @ingroup iface_qt_surface_extension */
98 static inline void *
99 qt_surface_extension_get_user_data(struct qt_surface_extension *qt_surface_extension)
100 {
101 return wl_proxy_get_user_data((struct wl_proxy *) qt_surface_extension);
102 }
103
104 static inline uint32_t
105 qt_surface_extension_get_version(struct qt_surface_extension *qt_surface_extension)
106 {
107 return wl_proxy_get_version((struct wl_proxy *) qt_surface_extension);
108 }
109
110 /** @ingroup iface_qt_surface_extension */
111 static inline void
112 qt_surface_extension_destroy(struct qt_surface_extension *qt_surface_extension)
113 {
114 wl_proxy_destroy((struct wl_proxy *) qt_surface_extension);
115 }
116
117 /**
118 * @ingroup iface_qt_surface_extension
119 */
120 static inline struct qt_extended_surface *
121 qt_surface_extension_get_extended_surface(struct qt_surface_extension *qt_surface_extension, struct wl_surface *surface)
122 {
123 struct wl_proxy *id;
124
125 id = wl_proxy_marshal_constructor((struct wl_proxy *) qt_surface_extension,
126 QT_SURFACE_EXTENSION_GET_EXTENDED_SURFACE, &qt_extended_surface_interface, NULL, surface);
127
128 return (struct qt_extended_surface *) id;
129 }
130
131 #ifndef QT_EXTENDED_SURFACE_ORIENTATION_ENUM
132 #define QT_EXTENDED_SURFACE_ORIENTATION_ENUM
133 enum qt_extended_surface_orientation {
134 QT_EXTENDED_SURFACE_ORIENTATION_PRIMARYORIENTATION = 0,
135 QT_EXTENDED_SURFACE_ORIENTATION_PORTRAITORIENTATION = 1,
136 QT_EXTENDED_SURFACE_ORIENTATION_LANDSCAPEORIENTATION = 2,
137 QT_EXTENDED_SURFACE_ORIENTATION_INVERTEDPORTRAITORIENTATION = 4,
138 QT_EXTENDED_SURFACE_ORIENTATION_INVERTEDLANDSCAPEORIENTATION = 8,
139 };
140 #endif /* QT_EXTENDED_SURFACE_ORIENTATION_ENUM */
141
142 #ifndef QT_EXTENDED_SURFACE_WINDOWFLAG_ENUM
143 #define QT_EXTENDED_SURFACE_WINDOWFLAG_ENUM
144 enum qt_extended_surface_windowflag {
145 QT_EXTENDED_SURFACE_WINDOWFLAG_OVERRIDESSYSTEMGESTURES = 1,
146 QT_EXTENDED_SURFACE_WINDOWFLAG_STAYSONTOP = 2,
147 QT_EXTENDED_SURFACE_WINDOWFLAG_BYPASSWINDOWMANAGER = 4,
148 };
149 #endif /* QT_EXTENDED_SURFACE_WINDOWFLAG_ENUM */
150
151 /**
152 * @ingroup iface_qt_extended_surface
153 * @struct qt_extended_surface_listener
154 */
155 struct qt_extended_surface_listener {
156 /**
157 */
158 void (*onscreen_visibility)(void *data,
159 struct qt_extended_surface *qt_extended_surface,
160 int32_t visible);
161 /**
162 */
163 void (*set_generic_property)(void *data,
164 struct qt_extended_surface *qt_extended_surface,
165 const char *name,
166 struct wl_array *value);
167 /**
168 */
169 void (*close)(void *data,
170 struct qt_extended_surface *qt_extended_surface);
171 };
172
173 /**
174 * @ingroup iface_qt_extended_surface
175 */
176 static inline int
177 qt_extended_surface_add_listener(struct qt_extended_surface *qt_extended_surface,
178 const struct qt_extended_surface_listener *listener, void *data)
179 {
180 return wl_proxy_add_listener((struct wl_proxy *) qt_extended_surface,
181 (void (**)(void)) listener, data);
182 }
183
184 #define QT_EXTENDED_SURFACE_UPDATE_GENERIC_PROPERTY 0
185 #define QT_EXTENDED_SURFACE_SET_CONTENT_ORIENTATION_MASK 1
186 #define QT_EXTENDED_SURFACE_SET_WINDOW_FLAGS 2
187 #define QT_EXTENDED_SURFACE_RAISE 3
188 #define QT_EXTENDED_SURFACE_LOWER 4
189
190 /**
191 * @ingroup iface_qt_extended_surface
192 */
193 #define QT_EXTENDED_SURFACE_ONSCREEN_VISIBILITY_SINCE_VERSION 1
194 /**
195 * @ingroup iface_qt_extended_surface
196 */
197 #define QT_EXTENDED_SURFACE_SET_GENERIC_PROPERTY_SINCE_VERSION 1
198 /**
199 * @ingroup iface_qt_extended_surface
200 */
201 #define QT_EXTENDED_SURFACE_CLOSE_SINCE_VERSION 1
202
203 /**
204 * @ingroup iface_qt_extended_surface
205 */
206 #define QT_EXTENDED_SURFACE_UPDATE_GENERIC_PROPERTY_SINCE_VERSION 1
207 /**
208 * @ingroup iface_qt_extended_surface
209 */
210 #define QT_EXTENDED_SURFACE_SET_CONTENT_ORIENTATION_MASK_SINCE_VERSION 1
211 /**
212 * @ingroup iface_qt_extended_surface
213 */
214 #define QT_EXTENDED_SURFACE_SET_WINDOW_FLAGS_SINCE_VERSION 1
215 /**
216 * @ingroup iface_qt_extended_surface
217 */
218 #define QT_EXTENDED_SURFACE_RAISE_SINCE_VERSION 1
219 /**
220 * @ingroup iface_qt_extended_surface
221 */
222 #define QT_EXTENDED_SURFACE_LOWER_SINCE_VERSION 1
223
224 /** @ingroup iface_qt_extended_surface */
225 static inline void
226 qt_extended_surface_set_user_data(struct qt_extended_surface *qt_extended_surface, void *user_data)
227 {
228 wl_proxy_set_user_data((struct wl_proxy *) qt_extended_surface, user_data);
229 }
230
231 /** @ingroup iface_qt_extended_surface */
232 static inline void *
233 qt_extended_surface_get_user_data(struct qt_extended_surface *qt_extended_surface)
234 {
235 return wl_proxy_get_user_data((struct wl_proxy *) qt_extended_surface);
236 }
237
238 static inline uint32_t
239 qt_extended_surface_get_version(struct qt_extended_surface *qt_extended_surface)
240 {
241 return wl_proxy_get_version((struct wl_proxy *) qt_extended_surface);
242 }
243
244 /** @ingroup iface_qt_extended_surface */
245 static inline void
246 qt_extended_surface_destroy(struct qt_extended_surface *qt_extended_surface)
247 {
248 wl_proxy_destroy((struct wl_proxy *) qt_extended_surface);
249 }
250
251 /**
252 * @ingroup iface_qt_extended_surface
253 */
254 static inline void
255 qt_extended_surface_update_generic_property(struct qt_extended_surface *qt_extended_surface, const char *name, struct wl_array *value)
256 {
257 wl_proxy_marshal((struct wl_proxy *) qt_extended_surface,
258 QT_EXTENDED_SURFACE_UPDATE_GENERIC_PROPERTY, name, value);
259 }
260
261 /**
262 * @ingroup iface_qt_extended_surface
263 */
264 static inline void
265 qt_extended_surface_set_content_orientation_mask(struct qt_extended_surface *qt_extended_surface, int32_t orientation)
266 {
267 wl_proxy_marshal((struct wl_proxy *) qt_extended_surface,
268 QT_EXTENDED_SURFACE_SET_CONTENT_ORIENTATION_MASK, orientation);
269 }
270
271 /**
272 * @ingroup iface_qt_extended_surface
273 */
274 static inline void
275 qt_extended_surface_set_window_flags(struct qt_extended_surface *qt_extended_surface, int32_t flags)
276 {
277 wl_proxy_marshal((struct wl_proxy *) qt_extended_surface,
278 QT_EXTENDED_SURFACE_SET_WINDOW_FLAGS, flags);
279 }
280
281 /**
282 * @ingroup iface_qt_extended_surface
283 */
284 static inline void
285 qt_extended_surface_raise(struct qt_extended_surface *qt_extended_surface)
286 {
287 wl_proxy_marshal((struct wl_proxy *) qt_extended_surface,
288 QT_EXTENDED_SURFACE_RAISE);
289 }
290
291 /**
292 * @ingroup iface_qt_extended_surface
293 */
294 static inline void
295 qt_extended_surface_lower(struct qt_extended_surface *qt_extended_surface)
296 {
297 wl_proxy_marshal((struct wl_proxy *) qt_extended_surface,
298 QT_EXTENDED_SURFACE_LOWER);
299 }
300
301 #ifdef __cplusplus
302 }
303 #endif
304
305 #endif