mirror of
https://github.com/brl/mutter.git
synced 2025-01-29 21:02:21 +00:00
b4fe1fdd95
We setup Xwayland in an early phase of the X11 display, before we had a MetaX11Display, and teared down in a couple of places happening when tearing down the Xwayland integration if the X server died or terminated. It was a bit hard to follow what happened and when it happened. Attempt to clean this up a bit, with things being structured as follows: * Early during X11 display connection setup, only setup the rudimentary X11 hooks, being the libX11 error callbacks, and adding the local user to XHost. * Move "initialize Xwayland component" code to a new 'x11-display-setup' signal handler. Things setup here are cleaned up in the 'x11-display-closing' handler. * Connect to 'x11-display-setup' and 'x11-display-closing' up front, and stay connected to these two. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1796>