diff --git a/src/core/frame.c b/src/core/frame.c index 8901aad31..13cbbd209 100644 --- a/src/core/frame.c +++ b/src/core/frame.c @@ -26,6 +26,7 @@ #include "bell.h" #include #include "keybindings-private.h" +#include "backends/x11/meta-backend-x11.h" #define EVENT_MASK (SubstructureRedirectMask | \ StructureNotifyMask | SubstructureNotifyMask | \ @@ -159,10 +160,16 @@ meta_window_ensure_frame (MetaWindow *window) meta_ui_map_frame (frame->window->screen->ui, frame->xwindow); - /* Since the backend takes keygrabs on another connection, make sure - * to sync the GTK+ connection to ensure that the frame window has - * been created on the server at this point. */ - XSync (window->display->xdisplay, False); + { + MetaBackend *backend = meta_get_backend (); + if (META_IS_BACKEND_X11 (backend)) + { + /* Since the backend takes keygrabs on another connection, make sure + * to sync the GTK+ connection to ensure that the frame window has + * been created on the server at this point. */ + XSync (window->display->xdisplay, False); + } + } /* Move keybindings to frame instead of window */ meta_window_grab_keys (window);