summaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
authoremersion <contact@emersion.fr>2019-01-17 11:14:36 +0100
committeremersion <contact@emersion.fr>2019-01-17 11:14:36 +0100
commitea2ee627e3477627a70bfe468529a2f888a541fb (patch)
treef2388ecaac82f6ab61e962303f60ccd03df923be /main.c
parentab0716cf2fd050d4e0d298eba290c76f5e31c32a (diff)
downloadswaybg-ea2ee627e3477627a70bfe468529a2f888a541fb.tar.gz
swaybg-ea2ee627e3477627a70bfe468529a2f888a541fb.tar.bz2
swaybg: use wl_surface_damage_buffer
Diffstat (limited to '')
-rw-r--r--main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/main.c b/main.c
index e3ef3d7..5678a67 100644
--- a/main.c
+++ b/main.c
@@ -104,7 +104,7 @@ static void render_frame(struct swaybg_state *state) {
wl_surface_set_buffer_scale(state->surface, state->output->scale);
wl_surface_attach(state->surface, state->current_buffer->buffer, 0, 0);
- wl_surface_damage(state->surface, 0, 0, state->width, state->height);
+ wl_surface_damage_buffer(state->surface, 0, 0, INT32_MAX, INT32_MAX);
wl_surface_commit(state->surface);
}
@@ -223,7 +223,7 @@ static void handle_global(void *data, struct wl_registry *registry,
struct swaybg_state *state = data;
if (strcmp(interface, wl_compositor_interface.name) == 0) {
state->compositor =
- wl_registry_bind(registry, name, &wl_compositor_interface, 3);
+ wl_registry_bind(registry, name, &wl_compositor_interface, 4);
} else if (strcmp(interface, wl_shm_interface.name) == 0) {
state->shm = wl_registry_bind(registry, name, &wl_shm_interface, 1);
} else if (strcmp(interface, wl_output_interface.name) == 0) {