diff options
author | Alexander Orzechowski <alex@ozal.ski> | 2023-06-12 20:16:25 -0400 |
---|---|---|
committer | Simon Ser <contact@emersion.fr> | 2023-06-13 09:19:51 +0000 |
commit | 495bcbeedde21eaa9d68ceef1fba5109d5d50dee (patch) | |
tree | a091b0e173e8950b2608836fe12e0c5959d188de /examples/simple.c | |
parent | 0925a500d1b4709a6058b2d1174a5aab90a5e34e (diff) |
examples: Drop usage of wlr_output.pending
Diffstat (limited to 'examples/simple.c')
-rw-r--r-- | examples/simple.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/examples/simple.c b/examples/simple.c index 0c737106..fa52bce5 100644 --- a/examples/simple.c +++ b/examples/simple.c @@ -107,10 +107,11 @@ static void new_output_notify(struct wl_listener *listener, void *data) { struct wlr_output_mode *mode = wlr_output_preferred_mode(output); if (mode != NULL) { - wlr_output_set_mode(output, mode); + struct wlr_output_state state = {0}; + wlr_output_state_set_mode(&state, mode); + wlr_output_commit_state(sample_output->output, &state); + wlr_output_state_finish(&state); } - - wlr_output_commit(sample_output->output); } static void keyboard_key_notify(struct wl_listener *listener, void *data) { |