Init the damage_ring bounds on output creation

Otherwise the initial bounds would be `INT_MAX` until `handle_mode` or `handle_commit` is called :)
This commit is contained in:
Erik Reider 2023-03-26 15:47:26 +02:00 committed by Simon Ser
parent f21090f978
commit ac1ed638e9
1 changed files with 3 additions and 0 deletions

View File

@ -999,6 +999,9 @@ void handle_new_output(struct wl_listener *listener, void *data) {
}
output->server = server;
wlr_damage_ring_init(&output->damage_ring);
int width, height;
wlr_output_transformed_resolution(output->wlr_output, &width, &height);
wlr_damage_ring_set_bounds(&output->damage_ring, width, height);
wl_signal_add(&wlr_output->events.destroy, &output->destroy);
output->destroy.notify = handle_destroy;