X11: fix detect of window manager