From 9b1b95ca76686309a1ef6e3626185296e9e9ea10 Mon Sep 17 00:00:00 2001 From: marius vlad Date: Mon, 3 Apr 2023 19:45:25 +0300 Subject: [PATCH] libweston: Damage the output after the output has been added Rather than damaging the output before the output has been added with weston_compositor_add_output, do that afterwards as to avoid scheduling a repaint for that output *before* actually adding the output. This would avoid the awkward case where we attempt to set initial power state to normal, but we can't apply it at that stage. Signed-off-by: marius vlad --- libweston/compositor.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libweston/compositor.c b/libweston/compositor.c index 88a9f1bbd..f3ab043c0 100644 --- a/libweston/compositor.c +++ b/libweston/compositor.c @@ -7267,7 +7267,6 @@ weston_output_enable(struct weston_output *output) wl_list_init(&output->paint_node_z_order_list); weston_output_update_matrix(output); - weston_output_damage(output); weston_log("Output '%s' attempts EOTF mode: %s\n", output->name, weston_eotf_mode_to_str(output->eotf_mode)); @@ -7290,6 +7289,7 @@ weston_output_enable(struct weston_output *output) } weston_compositor_add_output(output->compositor, output); + weston_output_damage(output); head_names = weston_output_create_heads_string(output); weston_log("Output '%s' enabled with head(s) %s\n",