Xwayland: Do not map the COW by default when rootless

The composite overlay window (COW) can be queried from any X11 client,
not just the X11 compositing manager.

If a client tries to get the composite overlay window, the Xserver will
map the window and block all pointer events (the window being mapped and
on top of the stack).

To avoid that issue, unset the "mapped" state of the composite overlay
window once realized when Xwayland is running rootless.

Note: All Xservers are actually affected by this issue, but with most
regular X servers, the compositing manager will take care of dealing
with the composite overlay window, and an X11 client using
GetOverlayWindow() won't break pointer events for all X11 clients.
Wayland compositors however usually run Xwayland rootless and have no
use for the COW.

v2: Avoid registering damage for the COW (Michel)
v3: Remove the "mapped" test to avoid calling register_damage() if the
    COW is not mapped (Michel)

Closes: xorg/xserver#1314
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
4 jobs for xwayland-hide-that-cow in 2 minutes and 49 seconds (queued for 1 minute and 45 seconds)