Commit d6d01c85 authored by Carlos Garnacho's avatar Carlos Garnacho

wayland: Collect frame completion time once for all surfaces

Dispatch all surface frames with the same monotonic time to avoid
querying it too often.
parent d0bfb94f
......@@ -179,12 +179,14 @@ meta_wayland_compositor_update (MetaWaylandCompositor *compositor,
meta_wayland_compositor_paint_finished (MetaWaylandCompositor *compositor)
gint64 current_time = g_get_monotonic_time ();
while (!wl_list_empty (&compositor->frame_callbacks))
MetaWaylandFrameCallback *callback =
wl_container_of (compositor->, callback, link);
wl_callback_send_done (callback->resource, g_get_monotonic_time () / 1000);
wl_callback_send_done (callback->resource, current_time / 1000);
wl_resource_destroy (callback->resource);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment