aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar Erik Reider <35975961+ErikReider@users.noreply.github.com>2023-03-26 15:47:26 +0200
committerLibravatar Simon Ser <contact@emersion.fr>2023-03-26 23:00:08 +0200
commitac1ed638e991c9f5639176ce4ee07059b4f2e1ce (patch)
tree2ae37d409fea5621d53e0a33b9b22d0cc5bb3f69
parentroot: Set inactive focus when scratchpad is moved to new workspace (diff)
downloadsway-ac1ed638e991c9f5639176ce4ee07059b4f2e1ce.tar.gz
sway-ac1ed638e991c9f5639176ce4ee07059b4f2e1ce.tar.zst
sway-ac1ed638e991c9f5639176ce4ee07059b4f2e1ce.zip
Init the damage_ring bounds on output creation
Otherwise the initial bounds would be `INT_MAX` until `handle_mode` or `handle_commit` is called :)
-rw-r--r--sway/desktop/output.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sway/desktop/output.c b/sway/desktop/output.c
index 0c8a5fd4..09fc6462 100644
--- a/sway/desktop/output.c
+++ b/sway/desktop/output.c
@@ -999,6 +999,9 @@ void handle_new_output(struct wl_listener *listener, void *data) {
999 } 999 }
1000 output->server = server; 1000 output->server = server;
1001 wlr_damage_ring_init(&output->damage_ring); 1001 wlr_damage_ring_init(&output->damage_ring);
1002 int width, height;
1003 wlr_output_transformed_resolution(output->wlr_output, &width, &height);
1004 wlr_damage_ring_set_bounds(&output->damage_ring, width, height);
1002 1005
1003 wl_signal_add(&wlr_output->events.destroy, &output->destroy); 1006 wl_signal_add(&wlr_output->events.destroy, &output->destroy);
1004 output->destroy.notify = handle_destroy; 1007 output->destroy.notify = handle_destroy;