fix flatpak's sandboxed X11 support
Access to X11 should not be granted when wayland is available. For that, it is possible to use the fallback-x11 socket instead.
GTK can make use of OpenGL, so access to the direct rendering infrastructure should be granted.