aboutsummaryrefslogtreecommitdiffstats
path: root/swaybg
diff options
context:
space:
mode:
authorLibravatar emersion <contact@emersion.fr>2019-01-17 11:14:36 +0100
committerLibravatar emersion <contact@emersion.fr>2019-01-17 11:14:36 +0100
commit808d0e1c510207ec9a128cda492f391de06b3be8 (patch)
treee7f97fb938741c76f9297ee113de68332f880d63 /swaybg
parentswaybg: use output names instead of output indexes (diff)
downloadsway-808d0e1c510207ec9a128cda492f391de06b3be8.tar.gz
sway-808d0e1c510207ec9a128cda492f391de06b3be8.tar.zst
sway-808d0e1c510207ec9a128cda492f391de06b3be8.zip
swaybg: use wl_surface_damage_buffer
Diffstat (limited to 'swaybg')
-rw-r--r--swaybg/main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/swaybg/main.c b/swaybg/main.c
index e3ef3d7c..5678a671 100644
--- a/swaybg/main.c
+++ b/swaybg/main.c
@@ -104,7 +104,7 @@ static void render_frame(struct swaybg_state *state) {
104 104
105 wl_surface_set_buffer_scale(state->surface, state->output->scale); 105 wl_surface_set_buffer_scale(state->surface, state->output->scale);
106 wl_surface_attach(state->surface, state->current_buffer->buffer, 0, 0); 106 wl_surface_attach(state->surface, state->current_buffer->buffer, 0, 0);
107 wl_surface_damage(state->surface, 0, 0, state->width, state->height); 107 wl_surface_damage_buffer(state->surface, 0, 0, INT32_MAX, INT32_MAX);
108 wl_surface_commit(state->surface); 108 wl_surface_commit(state->surface);
109} 109}
110 110
@@ -223,7 +223,7 @@ static void handle_global(void *data, struct wl_registry *registry,
223 struct swaybg_state *state = data; 223 struct swaybg_state *state = data;
224 if (strcmp(interface, wl_compositor_interface.name) == 0) { 224 if (strcmp(interface, wl_compositor_interface.name) == 0) {
225 state->compositor = 225 state->compositor =
226 wl_registry_bind(registry, name, &wl_compositor_interface, 3); 226 wl_registry_bind(registry, name, &wl_compositor_interface, 4);
227 } else if (strcmp(interface, wl_shm_interface.name) == 0) { 227 } else if (strcmp(interface, wl_shm_interface.name) == 0) {
228 state->shm = wl_registry_bind(registry, name, &wl_shm_interface, 1); 228 state->shm = wl_registry_bind(registry, name, &wl_shm_interface, 1);
229 } else if (strcmp(interface, wl_output_interface.name) == 0) { 229 } else if (strcmp(interface, wl_output_interface.name) == 0) {