wlmaker
Loading...
Searching...
No Matches
libwlclient.h
Go to the documentation of this file.
1/* ========================================================================= */
21#ifndef __LIBWLCLIENT_H__
22#define __LIBWLCLIENT_H__
23
24#include <inttypes.h>
25#include <stdbool.h>
26#include <libbase/libbase.h>
27#include <wayland-server-core.h>
28#include <xkbcommon/xkbcommon.h>
29
31typedef struct _wlclient_t wlclient_t;
32struct zxdg_toplevel_decoration_v1;
33
34#include "icon.h"
35#include "xdg_toplevel.h"
36
37#ifdef __cplusplus
38extern "C" {
39#endif // __cplusplus
40
47typedef void (*wlclient_callback_t)(
48 wlclient_t *wlclient_ptr,
49 void *ud_ptr);
50
52typedef struct {
54 struct wl_display *wl_display_ptr;
56 struct wl_compositor *wl_compositor_ptr;
58 struct wl_shm *wl_shm_ptr;
60 struct xdg_wm_base *xdg_wm_base_ptr;
62 struct wl_seat *wl_seat_ptr;
64 struct wl_pointer *wl_pointer_ptr;
66 struct zwlmaker_icon_manager_v1 *icon_manager_ptr;
68 struct zxdg_decoration_manager_v1 *xdg_decoration_manager_ptr;
70 struct ext_input_observation_manager_v1 *input_observation_manager_ptr;
71
73 const char *app_id_ptr;
75
77typedef struct {
79 struct wl_signal key;
81
83typedef struct{
85 xkb_keysym_t keysym;
87 bool pressed;
89
98wlclient_t *wlclient_create(const char *app_id_ptr);
99
105void wlclient_destroy(wlclient_t *wlclient_ptr);
106
115 const wlclient_t *wlclient_ptr);
116
119
125void wlclient_run(wlclient_t *wlclient_ptr);
126
133void wlclient_request_terminate(wlclient_t *wlclient_ptr);
134
150 wlclient_t *wlclient_ptr,
151 uint64_t target_usec,
152 wlclient_callback_t callback,
153 void *callback_ud_ptr);
154
155#ifdef __cplusplus
156} // extern "C"
157#endif // __cplusplus
158
159#endif /* __LIBWLCLIENT_H__ */
160/* == End of libwlclient.h ================================================= */
wlclient_t * wlclient_create(const char *app_id_ptr)
Definition client.c:293
void wlclient_destroy(wlclient_t *wlclient_ptr)
Definition client.c:397
void wlclient_request_terminate(wlclient_t *wlclient_ptr)
Definition client.c:558
wlclient_events_t * wlclient_events(wlclient_t *wlclient_ptr)
Definition client.c:449
void(* wlclient_callback_t)(wlclient_t *wlclient_ptr, void *ud_ptr)
Definition libwlclient.h:47
const wlclient_attributes_t * wlclient_attributes(const wlclient_t *wlclient_ptr)
Definition client.c:442
bool wlclient_register_timer(wlclient_t *wlclient_ptr, uint64_t target_usec, wlclient_callback_t callback, void *callback_ud_ptr)
Definition client.c:564
struct _wlclient_t wlclient_t
Definition libwlclient.h:31
void wlclient_run(wlclient_t *wlclient_ptr)
Definition client.c:456
Definition client.c:58
Definition libwlclient.h:52
struct wl_compositor * wl_compositor_ptr
Definition libwlclient.h:56
struct wl_shm * wl_shm_ptr
Definition libwlclient.h:58
struct zwlmaker_icon_manager_v1 * icon_manager_ptr
Definition libwlclient.h:66
const char * app_id_ptr
Definition libwlclient.h:73
struct xdg_wm_base * xdg_wm_base_ptr
Definition libwlclient.h:60
struct zxdg_decoration_manager_v1 * xdg_decoration_manager_ptr
Definition libwlclient.h:68
struct wl_display * wl_display_ptr
Definition libwlclient.h:54
struct ext_input_observation_manager_v1 * input_observation_manager_ptr
Definition libwlclient.h:70
struct wl_pointer * wl_pointer_ptr
Definition libwlclient.h:64
struct wl_seat * wl_seat_ptr
Definition libwlclient.h:62
Definition libwlclient.h:77
struct wl_signal key
Definition libwlclient.h:79
Definition libwlclient.h:83
xkb_keysym_t keysym
Definition libwlclient.h:85
bool pressed
Definition libwlclient.h:87