diff options
author | Tony Crisci <tony@dubstepdish.com> | 2018-06-24 18:38:52 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-06-24 18:38:52 -0400 |
commit | 0fa784de0ec3ca6ddc336f714329d3551107a70b (patch) | |
tree | 98d77f3969726c2cf5c9901e0505a7ff698ad422 /rootston | |
parent | e459fe0ec713ea65b35b966f9bb3c6c70c9504aa (diff) | |
parent | 356e466d5a40f69b66af89cb0767d5bf6410bee4 (diff) |
Merge pull request #1054 from swaywm/cancel-grab-on-focus-change
rootston: Cancel existing keyboard grab when changing focus
Diffstat (limited to 'rootston')
-rw-r--r-- | rootston/seat.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/rootston/seat.c b/rootston/seat.c index 91561567..d8910660 100644 --- a/rootston/seat.c +++ b/rootston/seat.c @@ -825,6 +825,9 @@ void roots_seat_set_focus(struct roots_seat *seat, struct roots_view *view) { view_activate(view, true); seat->has_focus = true; + // An existing keyboard grab might try to deny setting focus, so cancel it + wlr_seat_keyboard_end_grab(seat->seat); + struct wlr_keyboard *keyboard = wlr_seat_get_keyboard(seat->seat); if (keyboard != NULL) { wlr_seat_keyboard_notify_enter(seat->seat, view->wlr_surface, |