aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Orzechowski <alex@ozal.ski>2023-06-27 12:30:30 -0400
committerAlexander Orzechowski <alex@ozal.ski>2023-08-16 11:46:27 -0400
commit869b0f14bc708883ff8e85c36e258658fa6ab475 (patch)
tree753fab7e40160ca27dd874cbc3ebc8398ec770b8
parent6cda3e251c8f78a376b3a239c2c4fd7fae1a3f3e (diff)
backend/x11: Use output state to set init custom mode
-rw-r--r--backend/x11/output.c8
1 files changed, 6 insertions, 2 deletions
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;