Skip to content

x11-display: Set NO_AT_BRIDGE to 1 while opening the GDK display

Jonas Ådahl requested to merge jadahl/mutter:wip/set-no-at-bridge-again into master

gnome-shell has this hack where it sets the environment variable "NO_AT_BRIDGE" to "1" before calling meta_init() and then unsets it after meta_init() returns.

This variable being set to "1" will then cause the ATK bridge in at-spi2-gtk to fail to load, which GTK then ignores. This is on purpose, since accessibility is supposed to be done done by GNOME Shell via Clutter, not via GTK.

The problem is that, now, by default, setting "NO_AT_BRIDGE" to "1" during meta_init() only has the desired effect on an X11 session, where we always connect to the X11 server on startup (i.e. during meta_init()). With Xwayland on-demand, we do not attempt to create the GDK display during meta_init(), thus this hack falls apart.

Since there are no real altenatives to this hack, just move it to mutter, which have a better idea when GDK displays are created or not.

Merge request reports