mirror of
https://github.com/brl/mutter.git
synced 2024-11-29 03:20:46 -05:00
wayland: Fix caching of surface state
The commit 97a69cee5a
broke the caching of
the surface state when because the frame_callback_list target state was
overwritten after the content had been moved to it.
This commit fixes it by moving the frame list addition after the copy. We
also need to initialize the list since the plain copy put garbage in it.
https://bugzilla.gnome.org/show_bug.cgi?id=743678
This commit is contained in:
parent
ad90b7dd2f
commit
4d23e7c202
@ -296,10 +296,11 @@ move_pending_state (MetaWaylandPendingState *from,
|
|||||||
if (from->buffer)
|
if (from->buffer)
|
||||||
wl_list_remove (&from->buffer_destroy_listener.link);
|
wl_list_remove (&from->buffer_destroy_listener.link);
|
||||||
|
|
||||||
wl_list_insert_list (&to->frame_callback_list, &from->frame_callback_list);
|
|
||||||
|
|
||||||
*to = *from;
|
*to = *from;
|
||||||
|
|
||||||
|
wl_list_init (&to->frame_callback_list);
|
||||||
|
wl_list_insert_list (&to->frame_callback_list, &from->frame_callback_list);
|
||||||
|
|
||||||
if (to->buffer)
|
if (to->buffer)
|
||||||
wl_signal_add (&to->buffer->destroy_signal, &to->buffer_destroy_listener);
|
wl_signal_add (&to->buffer->destroy_signal, &to->buffer_destroy_listener);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user