From 05993458e27d4821d37c0150c7c10e5f6cc2f29b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 18 Mar 2016 09:13:27 +0100 Subject: [PATCH] [server] Send frameRendered to all sub-surfaces If a surface got rendered it implies that all sub-surfaces also got rendered. So pass the frameRendered to the complete sub-surface tree. --- src/wayland/surface_interface.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/wayland/surface_interface.cpp b/src/wayland/surface_interface.cpp index d55cc3025f..e9a2f3f5e8 100644 --- a/src/wayland/surface_interface.cpp +++ b/src/wayland/surface_interface.cpp @@ -179,6 +179,13 @@ void SurfaceInterface::frameRendered(quint32 msec) wl_callback_send_done(r, msec); wl_resource_destroy(r); } + for (auto it = d->current.children.constBegin(); it != d->current.children.constEnd(); ++it) { + const auto &subSurface = *it; + if (subSurface.isNull() || subSurface->d_func()->surface.isNull()) { + continue; + } + subSurface->d_func()->surface->frameRendered(msec); + } if (needsFlush) { client()->flush(); }