clutter/stage-view: Initialize view as damaged and awaiting frame

Make sure that when we've recreated views that we'll actually paint a
new frame for it. This was very rarely a problem, as views tend to
result in getting damage etc being queued as side effects of various
things, like layout, but e.g. when running certain tests, this might not
happen. There is no situation where we want to create a new view that
should remain unpainted, so just make sure we initialize it to become up
to date.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1947>
This commit is contained in:
Jonas Ådahl 2021-07-30 11:28:28 +02:00 committed by Marge Bot
parent c8fb98a0a7
commit 18c414cca4

View File

@ -1369,6 +1369,9 @@ clutter_stage_view_constructed (GObject *object)
&frame_clock_listener_iface, &frame_clock_listener_iface,
view); view);
clutter_stage_view_add_redraw_clip (view, NULL);
clutter_stage_view_schedule_update (view);
G_OBJECT_CLASS (clutter_stage_view_parent_class)->constructed (object); G_OBJECT_CLASS (clutter_stage_view_parent_class)->constructed (object);
} }