libei/portal xtest breaks nested compositors (Gamescope)
Since a1333342 added hooking of XTest that wraps to using libei, Gamescope has started to fail to work.
Under Gnome:
Running gamescope from a TTY:
- Moving the cursor causes Gamescope to hang permanently
On wlroots:
- Moving the cursor causes Gamescope to hang permanently
Gamescope can be run as a nested compositor, in which, the XServer will attempt to use libei -> the desktop portal to XTest, which is wrong as it is not the right compositor.
Gamescope also uses XTest internally, as it maintains no real cursor state of its own, relying on the XServer's.