keyboard: drop hard X dependency

The code to listen for window manager changes only makes sense under
X, so don't use it under Wayland. In that case, we can just assume
that we are under GNOME shell when we find a wayland display.

https://bugzilla.gnome.org/show_bug.cgi?id=728679