Use allow commits to fix black shadows on resize
Xwayland may post damages for an X11 window as soon as the frame callback is triggered, while the X11 window manager/compositor has not yet finished updating the windows.
If Xwayland becomes compliant enough to not permit updates after the buffer has been committed (see ), then the partial redraw of the X11 window at the time it was posted will show on screen.
To avoid that issue, the X11 window manager can use the X11 property
_XWAYLAND_ALLOW_COMMITS to control when Xwayland should be allowed to
post the pending damages.
set_allow_commits() method to
MetaWindow which is a no-op on
plain X11 and native Wayland windows, and sets
on the toplevel X11 window on Xwayland.
Then hint Xwayland as to when it can post pending damages and commit the
Wayland buffer using the
set_allow_commits() API, based on window actor