Unfortunately the proposed move breaks a few important presentation scenarios for GL/Vulkan contents. Here are the relevant details:
1. The OpenGL/Vulkan rendering occurs in a subsurface placed over the client area of the main window surface. Wayland subsurfaces are only shown if the parent surface is mapped. 2. Surface reconfiguration (ack-ing new state etc) happens primarily during a (window_surface_)flush to ensure contents (e.g., size) and surface state are in sync and compatible in the same surface commit (lest we violate state constraints and the compositor disconnects us).
Many games do not perform any non-Vulkan/GL draw to the window when fullscreen, thus no (window_surface_)flush for the window, and in such cases:
For (1), committing contents to the subsurface will not show anything on screen unless we ensure the main window surface is mapped. Moving the `wayland_surface_ensure_contents` operation to VkSurface creation is not enough, since the associated window may not even be visible at that point (in which case we don't map), and then visibility can arbitrarily change during the lifetime of the VkSurface.
For (2), the only other chance (outside window_surface_flush) we get to reconfigure is when Vulkan/GL presents the contents. Doing this during VkSurface creation is not enough, since reconfigures (e.g., changing to fullscreen) don't typically involve the application recreating the VkSurface. Sometimes they might not even involve recreating the VkSwapchain, e.g., if the size doesn't change.