diff options
Diffstat (limited to 'src/core/keybindings.c')
-rw-r--r-- | src/core/keybindings.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/core/keybindings.c b/src/core/keybindings.c index fe5f0f00..f4eb01b1 100644 --- a/src/core/keybindings.c +++ b/src/core/keybindings.c @@ -1310,6 +1310,14 @@ meta_display_process_key_event (MetaDisplay *display, meta_ui_window_is_widget (screen->ui, event->xany.window)) return; + /* Use focused window when processing synthetic events from another client */ + if (window == NULL && event->xkey.send_event) { + Window focus = None; + int ret_to = RevertToPointerRoot; + XGetInputFocus (display->xdisplay, &focus, &ret_to); + window = meta_display_lookup_x_window (display, focus); + } + /* window may be NULL */ #ifdef HAVE_XKB |