client: Change default lifespan of wl_surface to match the window


This brings it more in-line with other platforms where the underlying
backing store has the lifespan of the window, implicitly fixing a
teardown issue with Qt Vulkan.

With this commit the wl_surface lifetime matches the QPlatformWindow, on
show and hide the shell surface is still recreated, with a null buffer
attached inbetween to get a blank slate as per the specification.

There is still some paths where a wl_surface is reset during the
platform window lifetime if the user ever converted a subsurface to a
toplevel or vice-versa, also for handling compositing restarts.

Task-number: QTBUG-125592
Change-Id: I449ec170a085c7c0fca504687556d702daddf79a
Reviewed-by: David Edmundson <davidedmundson@kde.org>
commitfa967a897115d14d4aaa78cc287a04869c233200
parented094c9cb86c5c40b344d5a094c0f29c5d2a2fd6
authorDavid Redondo <qt@david-redondo.de>
committerDavid Edmundson <davidedmundson@kde.org>
commit timeTue, 24 Sep 2024 09:40:41 +0100