The current xdg-shell wrappers don't match existing abstractions in the
xdg-shell protocol well, which makes it more difficult to refactor code
that is responsible for managing configure events and geometry in kwin.
Given that the xdg_decoration and the xdg_shell protocols are tightly
coupled together, I had to rewrite our wrappers for the xdg_decoration
protocol as well.
Summary:
So far all double-buffered properties in our implementation of xdg-shell
weren't actually double-buffered. When a property setter is invoked, we
pray to the God hoping that the client committed associated surface.
This change introduces private SurfaceRole class. The new class provides
a way for SurfaceInterface to commit pending state of associated shell
surface.
The chosen architecture allows us to do more in the future. For example,
we could use SurfaceRole to prevent associating several roles to a single
wl_surface object, e.g. xdg-toplevel to a pointer surface, etc.
Test Plan: This change breaks support for client-side decorated clients in KWin.
Reviewers: #kwin
Subscribers: kde-frameworks-devel
Tags: #frameworks
Differential Revision: https://phabricator.kde.org/D23745