aboutsummaryrefslogtreecommitdiff
path: root/registry.c
diff options
context:
space:
mode:
Diffstat (limited to 'registry.c')
-rw-r--r--registry.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/registry.c b/registry.c
index bee7d1b..69f2370 100644
--- a/registry.c
+++ b/registry.c
@@ -2,7 +2,6 @@
#include <string.h>
#include "./state.h"
-#include "wayland.h"
struct wl_registry_listener registry_listener;
@@ -11,6 +10,9 @@ void setup_registry(client_state* state) {
wl_registry_add_listener(state->registry, &registry_listener, state);
wl_display_roundtrip(state->display);
}
+
+// listeners
+
void global(void *data, struct wl_registry *wl_registry, uint32_t name, const char *interface, uint32_t version) {
client_state* state = data;
@@ -20,7 +22,7 @@ void global(void *data, struct wl_registry *wl_registry, uint32_t name, const ch
state->compositor = wl_registry_bind(wl_registry, name, &wl_compositor_interface, 1);
}
else if (!strcmp(interface, wl_seat_interface.name)) {
- setup_seat(state, name);
+ state->seat = wl_registry_bind(state->registry, name, &wl_seat_interface, 1);
}
else if (!strcmp(interface, zwlr_layer_shell_v1_interface.name)) {
state->layer_shell = wl_registry_bind(wl_registry, name, &zwlr_layer_shell_v1_interface, version);