From 869b0f14bc708883ff8e85c36e258658fa6ab475 Mon Sep 17 00:00:00 2001 From: Alexander Orzechowski Date: Tue, 27 Jun 2023 12:30:30 -0400 Subject: backend/x11: Use output state to set init custom mode --- backend/x11/output.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'backend') diff --git a/backend/x11/output.c b/backend/x11/output.c index 81cb5961..d95f0767 100644 --- a/backend/x11/output.c +++ b/backend/x11/output.c @@ -539,9 +539,13 @@ struct wlr_output *wlr_x11_output_create(struct wlr_backend *backend) { pixman_region32_init(&output->exposed); struct wlr_output *wlr_output = &output->wlr_output; - wlr_output_init(wlr_output, &x11->backend, &output_impl, x11->wl_display, NULL); - wlr_output_update_custom_mode(wlr_output, 1024, 768, 0); + struct wlr_output_state state; + wlr_output_state_init(&state); + wlr_output_state_set_custom_mode(&state, 1024, 768, 0); + + wlr_output_init(wlr_output, &x11->backend, &output_impl, x11->wl_display, &state); + wlr_output_state_finish(&state); size_t output_num = ++last_output_num; -- cgit v1.2.3