This commit is contained in:
2022-08-28 16:02:32 +02:00
parent a661eddfd8
commit 81e2592c42
2 changed files with 2 additions and 13 deletions

Binary file not shown.

View File

@@ -29,21 +29,12 @@ static void registry_handle_global(void *data, struct wl_registry *registry, uin
{ {
struct client_state *state = data; struct client_state *state = data;
printf("interface: '%s', version: %d, name: %d\n", interface, version, name);
if (strcmp(interface, wl_compositor_interface.name) == 0) { if (strcmp(interface, wl_compositor_interface.name) == 0) {
state->wl_compositor = wl_registry_bind(registry, name, &wl_compositor_interface, 5); state->wl_compositor = wl_registry_bind(registry, name, &wl_compositor_interface, 5);
printf("Bound to compositor!\n"); } else if (strcmp(interface, wl_shm_interface.name) == 0) {
}
if (strcmp(interface, wl_shm_interface.name) == 0) {
state->wl_shm = wl_registry_bind(registry, name, &wl_shm_interface, 1); state->wl_shm = wl_registry_bind(registry, name, &wl_shm_interface, 1);
printf("Bound to shm!\n"); } else if (strcmp(interface, xdg_wm_base_interface.name) == 0) {
}
if (strcmp(interface, xdg_wm_base_interface.name) == 0) {
state->xdg_wm_base = wl_registry_bind(registry, name, &xdg_wm_base_interface, 4); state->xdg_wm_base = wl_registry_bind(registry, name, &xdg_wm_base_interface, 4);
printf("Bound to wm_base!\n");
} }
} }
@@ -55,8 +46,6 @@ static void registry_handle_global_remove(void *data, struct wl_registry *regist
static void shm_handle_format(void *data, struct wl_shm *wl_shm, uint32_t format) static void shm_handle_format(void *data, struct wl_shm *wl_shm, uint32_t format)
{ {
struct client_state *state = data; struct client_state *state = data;
printf("shm_handle_format: supported format is [%d]\n", format);
} }
static void wm_base_handle_ping(void *data, struct xdg_wm_base *xdg_wm_base, uint32_t serial) static void wm_base_handle_ping(void *data, struct xdg_wm_base *xdg_wm_base, uint32_t serial)