Commit e1279e51 authored by Vlad Zahorodnii's avatar Vlad Zahorodnii
Browse files

wayland: Track already existing subsurfaces in SubSurfaceMonitor

When the monitor is created, the surface may already have child
sub-surfaces. The childSubSurfaceAdded signal won't be emitted for them,
we need to handle this case explicitly.

BUG: 433511
FIXED-IN: 5.21.2
parent 73dd65f4
......@@ -66,6 +66,11 @@ void SubSurfaceMonitor::registerSurface(SurfaceInterface *surface)
this, &SubSurfaceMonitor::registerSubSurface);
connect(surface, &SurfaceInterface::childSubSurfaceRemoved,
this, &SubSurfaceMonitor::unregisterSubSurface);
const QList<SubSurfaceInterface *> childSubSurfaces = surface->childSubSurfaces();
for (SubSurfaceInterface *childSubSurface : childSubSurfaces) {
void SubSurfaceMonitor::unregisterSurface(SurfaceInterface *surface)
Supports Markdown
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