Details
-
Task
-
Resolution: Done
-
P2: Important
-
None
-
None
Description
In the beginning, there was a direct mapping between a QWaylandWindow and a wl_surface.
With xdg_shell (and other shell) this is not the case anymore. Changing certain properties of a QWindow requires creating a new wl_surface (because it changes role). This is problematic because some parts of the platform plugin relies on this assumption to identify if the wl_surface has changed.
We should therefore use composition rather than inheritance. I.e. a QWaylandWindow may have a wl_surface.
Furthermore, ownership may not even be direct, i.e. the QWaylandWindow may have an xdg_surface which has a wl_surface.
This would also hopefully let us reuse the new wl_surface class for things that are not a QPlatformWindow, but still require a wl_surface, such as the cursor surface, or parts of window decorations.