wlmaker
Loading...
Searching...
No Matches
surface.h
Go to the documentation of this file.
1/* ========================================================================= */
20#ifndef __WLMTK_SURFACE_H__
21#define __WLMTK_SURFACE_H__
22
23#include <libbase/libbase.h>
24#include <stdbool.h>
25#include <wayland-server-core.h>
26
27struct _wlmtk_surface_t;
31typedef struct _wlmtk_surface_vmt_t wlmtk_surface_vmt_t;
35
36#include "element.h"
37
39struct wlr_seat;
40struct wlr_surface;
41
42#ifdef __cplusplus
43extern "C" {
44#endif // __cplusplus
45
53 struct wlr_seat *wlr_seat_ptr;
54
56 struct wlr_surface *wlr_surface_ptr;
57
59 struct wlr_scene_tree *wlr_scene_tree_ptr;
62
67
69 struct wl_listener surface_commit_listener;
71 struct wl_listener surface_map_listener;
73 struct wl_listener surface_unmap_listener;
74
77
80};
81
83typedef wlmtk_surface_t *(*wlmtk_surface_create_t)(
84 struct wlr_surface *wlr_surface_ptr,
85 struct wlr_seat *wlr_seat_ptr);
86
97 struct wlr_surface *wlr_surface_ptr,
98 struct wlr_seat *wlr_seat_ptr);
99
105void wlmtk_surface_destroy(wlmtk_surface_t *surface_ptr);
106
107
116
125 wlmtk_surface_t *surface_ptr,
126 int *width_ptr,
127 int *height_ptr);
128
136 wlmtk_surface_t *surface_ptr,
137 bool activated);
138
141 wlmtk_surface_t *surface_ptr,
142 struct wl_listener *listener_ptr,
143 wl_notify_func_t handler);
146 wlmtk_surface_t *surface_ptr,
147 struct wl_listener *listener_ptr,
148 wl_notify_func_t handler);
149
151extern const bs_test_case_t wlmtk_surface_test_cases[];
152
158
161
164 struct wlr_surface *wlr_surface_ptr,
165 struct wlr_seat *wlr_seat_ptr);
166
169 wlmtk_fake_surface_t *fake_surface_ptr,
170 int width,
171 int height);
172
175
176#ifdef __cplusplus
177} // extern "C"
178#endif // __cplusplus
179
180#endif /* __WLMTK_SURFACE_H__ */
181/* == End of surface.h ===================================================== */
Definition element.h:175
Definition element.h:67
Definition surface.h:154
wlmtk_surface_t surface
Definition surface.h:156
Definition surface.h:47
struct wlr_scene_tree * wlr_scene_tree_ptr
Definition surface.h:59
int committed_height
Definition surface.h:66
bool activated
Definition surface.h:79
struct wl_listener element_pointer_leave_listener
Definition surface.h:76
struct wlr_seat * wlr_seat_ptr
Definition surface.h:53
struct wl_listener surface_map_listener
Definition surface.h:71
struct wlr_surface * wlr_surface_ptr
Definition surface.h:56
wlmtk_element_vmt_t orig_super_element_vmt
Definition surface.h:51
struct wl_listener surface_unmap_listener
Definition surface.h:73
int committed_width
Definition surface.h:64
struct wl_listener wlr_scene_tree_node_destroy_listener
Definition surface.h:61
struct wl_listener surface_commit_listener
Definition surface.h:69
wlmtk_element_t super_element
Definition surface.h:49
void wlmtk_surface_destroy(wlmtk_surface_t *surface_ptr)
Definition surface.c:137
void wlmtk_surface_get_size(wlmtk_surface_t *surface_ptr, int *width_ptr, int *height_ptr)
Definition surface.c:150
void wlmtk_fake_surface_destroy(wlmtk_fake_surface_t *fake_surface_ptr)
Definition surface.c:781
struct _wlmtk_surface_vmt_t wlmtk_surface_vmt_t
Definition surface.h:31
void wlmtk_fake_surface_commit_size(wlmtk_fake_surface_t *fake_surface_ptr, int width, int height)
Definition surface.c:772
wlmtk_element_t * wlmtk_surface_element(wlmtk_surface_t *surface_ptr)
Definition surface.c:144
void wlmtk_surface_connect_map_listener_signal(wlmtk_surface_t *surface_ptr, struct wl_listener *listener_ptr, wl_notify_func_t handler)
Definition surface.c:197
wlmtk_surface_t * wlmtk_fake_surface_create_inject(struct wlr_surface *wlr_surface_ptr, struct wlr_seat *wlr_seat_ptr)
Definition surface.c:762
const bs_test_case_t wlmtk_surface_test_cases[]
Definition surface.c:846
wlmtk_fake_surface_t * wlmtk_fake_surface_create(void)
Definition surface.c:748
void wlmtk_surface_connect_unmap_listener_signal(wlmtk_surface_t *surface_ptr, struct wl_listener *listener_ptr, wl_notify_func_t handler)
Definition surface.c:210
wlmtk_surface_t * wlmtk_surface_create(struct wlr_surface *wlr_surface_ptr, struct wlr_seat *wlr_seat_ptr)
Definition surface.c:120
void wlmtk_surface_set_activated(wlmtk_surface_t *surface_ptr, bool activated)
Definition surface.c:160