mirror of
https://github.com/hyprwm/wlroots-hyprland.git
synced 2024-11-05 13:05:59 +01:00
use seat function to end grab
This commit is contained in:
parent
e8c0996b93
commit
356e466d5a
1 changed files with 2 additions and 4 deletions
|
@ -825,10 +825,8 @@ void roots_seat_set_focus(struct roots_seat *seat, struct roots_view *view) {
|
|||
view_activate(view, true);
|
||||
seat->has_focus = true;
|
||||
|
||||
// We want to unconditionally send keyboard input to the view we are
|
||||
// focusing here, so cancel any existing grabs.
|
||||
struct wlr_seat_keyboard_grab *curr_grab = seat->seat->keyboard_state.grab;
|
||||
curr_grab->interface->cancel(curr_grab);
|
||||
// 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) {
|
||||
|
|
Loading…
Reference in a new issue