My KWIN fork where I work on features like per-output virtual desktops
Find a file
Martin Gräßlin d727d2e477 [server] Workaround for QtWayland bug https://bugreports.qt.io/browse/QTBUG-52192
Summary:
QtWayland doesn't map the parent sub-surfaces in a sub-surface tree.
According to the spec this would mean also the child sub-surface is not
mapped. But being strict according to the spec will make applications
like SystemSettings fail badly. Embedded child windows will not be
rendered and QtWayland is going to hard freeze. This is not acceptable,
thus we need to workaround this QtWayland bug till it's fixed.

It's worth mentioning that Weston as the reference compositor also
doesn't handle this situation according to spec and renders the
sub-surface. See https://bugs.freedesktop.org/show_bug.cgi?id=94735

The difficult part for the workaround is to determine whether a surface
should be considered unmapped. E.g. when the parent gets unmapped we need
to really unmap it. But what's the difference between an unmapped parent
surface which should be considered mapped and an unmapped parent surface
which should be considered unmapped?

The implementation goes with considering a new sub-surface always as
mapped - independently of whether it ever got a buffer attached. As soon
as it had a buffer attached and it gets unmapped again, it will go back
to a standard conform way.

The behavior now is not standard conform, thus the autotest is adjusted
to have QEXPECT_FAIL for the now no longer standard conform areas.

Reviewers: #plasma

Subscribers: plasma-devel

Projects: #plasma

Differential Revision: https://phabricator.kde.org/D1250
2016-04-04 08:55:59 +02:00
src/wayland [server] Workaround for QtWayland bug https://bugreports.qt.io/browse/QTBUG-52192 2016-04-04 08:55:59 +02:00