wlmaker
Loading...
Searching...
No Matches
libwlclient.h
Go to the documentation of this file.
1/* ========================================================================= */
20#ifndef __LIBWLCLIENT_H__
21#define __LIBWLCLIENT_H__
22
23#include <inttypes.h>
24#include <stdbool.h>
25#include <libbase/libbase.h>
26#include <wayland-server-core.h>
27#include <xkbcommon/xkbcommon.h>
28
30typedef struct _wlclient_t wlclient_t;
31struct zxdg_toplevel_decoration_v1;
32
33#include "icon.h"
34#include "xdg_toplevel.h"
35
36#ifdef __cplusplus
37extern "C" {
38#endif // __cplusplus
39
46typedef void (*wlclient_callback_t)(
47 wlclient_t *wlclient_ptr,
48 void *ud_ptr);
49
51typedef struct {
53 struct wl_display *wl_display_ptr;
55 struct wl_compositor *wl_compositor_ptr;
57 struct wl_shm *wl_shm_ptr;
59 struct xdg_wm_base *xdg_wm_base_ptr;
61 struct wl_seat *wl_seat_ptr;
63 struct wl_pointer *wl_pointer_ptr;
65 struct zwlmaker_icon_manager_v1 *icon_manager_ptr;
67 struct zxdg_decoration_manager_v1 *xdg_decoration_manager_ptr;
69 struct ext_input_observation_manager_v1 *input_observation_manager_ptr;
70
72 const char *app_id_ptr;
74
76typedef struct {
78 struct wl_signal key;
80
82typedef struct{
84 xkb_keysym_t keysym;
86 bool pressed;
88
97wlclient_t *wlclient_create(const char *app_id_ptr);
98
104void wlclient_destroy(wlclient_t *wlclient_ptr);
105
114 const wlclient_t *wlclient_ptr);
115
118
124void wlclient_run(wlclient_t *wlclient_ptr);
125
132void wlclient_request_terminate(wlclient_t *wlclient_ptr);
133
149 wlclient_t *wlclient_ptr,
150 uint64_t target_usec,
151 wlclient_callback_t callback,
152 void *callback_ud_ptr);
153
154#ifdef __cplusplus
155} // extern "C"
156#endif // __cplusplus
157
158#endif /* __LIBWLCLIENT_H__ */
159/* == End of libwlclient.h ================================================= */
wlclient_t * wlclient_create(const char *app_id_ptr)
Definition client.c:292
void wlclient_destroy(wlclient_t *wlclient_ptr)
Definition client.c:396
void wlclient_request_terminate(wlclient_t *wlclient_ptr)
Definition client.c:557
wlclient_events_t * wlclient_events(wlclient_t *wlclient_ptr)
Definition client.c:448
void(* wlclient_callback_t)(wlclient_t *wlclient_ptr, void *ud_ptr)
Definition libwlclient.h:46
const wlclient_attributes_t * wlclient_attributes(const wlclient_t *wlclient_ptr)
Definition client.c:441
bool wlclient_register_timer(wlclient_t *wlclient_ptr, uint64_t target_usec, wlclient_callback_t callback, void *callback_ud_ptr)
Definition client.c:563
struct _wlclient_t wlclient_t
Definition libwlclient.h:30
void wlclient_run(wlclient_t *wlclient_ptr)
Definition client.c:455
Definition client.c:57
Definition libwlclient.h:51
struct wl_compositor * wl_compositor_ptr
Definition libwlclient.h:55
struct wl_shm * wl_shm_ptr
Definition libwlclient.h:57
struct zwlmaker_icon_manager_v1 * icon_manager_ptr
Definition libwlclient.h:65
const char * app_id_ptr
Definition libwlclient.h:72
struct xdg_wm_base * xdg_wm_base_ptr
Definition libwlclient.h:59
struct zxdg_decoration_manager_v1 * xdg_decoration_manager_ptr
Definition libwlclient.h:67
struct wl_display * wl_display_ptr
Definition libwlclient.h:53
struct ext_input_observation_manager_v1 * input_observation_manager_ptr
Definition libwlclient.h:69
struct wl_pointer * wl_pointer_ptr
Definition libwlclient.h:63
struct wl_seat * wl_seat_ptr
Definition libwlclient.h:61
Definition libwlclient.h:76
struct wl_signal key
Definition libwlclient.h:78
Definition libwlclient.h:82
xkb_keysym_t keysym
Definition libwlclient.h:84
bool pressed
Definition libwlclient.h:86