aboutsummaryrefslogtreecommitdiffstats
path: root/sway/input/seat.c
diff options
context:
space:
mode:
authorLibravatar Tony Crisci <tony@dubstepdish.com>2017-12-17 08:30:20 -0500
committerLibravatar Tony Crisci <tony@dubstepdish.com>2017-12-17 08:30:20 -0500
commite27eff8a29abd74448322ae78baa99a489e43620 (patch)
tree8ad1ad5998604a9e44c3cbd642a3b1921116b7fd /sway/input/seat.c
parentset keyboard config at runtime (diff)
downloadsway-e27eff8a29abd74448322ae78baa99a489e43620.tar.gz
sway-e27eff8a29abd74448322ae78baa99a489e43620.tar.zst
sway-e27eff8a29abd74448322ae78baa99a489e43620.zip
send keyboard enter on keyboard configuration
Diffstat (limited to 'sway/input/seat.c')
-rw-r--r--sway/input/seat.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/sway/input/seat.c b/sway/input/seat.c
index 1e62efa1..8fe82b46 100644
--- a/sway/input/seat.c
+++ b/sway/input/seat.c
@@ -68,6 +68,13 @@ static void seat_configure_keyboard(struct sway_seat *seat,
68 sway_keyboard_create(seat, seat_device); 68 sway_keyboard_create(seat, seat_device);
69 } 69 }
70 sway_keyboard_configure(seat_device->keyboard); 70 sway_keyboard_configure(seat_device->keyboard);
71 wlr_seat_set_keyboard(seat->wlr_seat,
72 seat_device->input_device->wlr_device);
73 if (seat->focus) {
74 // force notify reenter to pick up the new configuration
75 wlr_seat_keyboard_clear_focus(seat->wlr_seat);
76 wlr_seat_keyboard_notify_enter(seat->wlr_seat, seat->focus->sway_view->surface);
77 }
71} 78}
72 79
73static struct sway_seat_device *sway_seat_get_device(struct sway_seat *seat, 80static struct sway_seat_device *sway_seat_get_device(struct sway_seat *seat,
@@ -101,8 +108,6 @@ void sway_seat_configure_device(struct sway_seat *seat,
101 break; 108 break;
102 case WLR_INPUT_DEVICE_KEYBOARD: 109 case WLR_INPUT_DEVICE_KEYBOARD:
103 seat_configure_keyboard(seat, seat_device); 110 seat_configure_keyboard(seat, seat_device);
104 wlr_seat_set_keyboard(seat->wlr_seat,
105 seat_device->input_device->wlr_device);
106 break; 111 break;
107 case WLR_INPUT_DEVICE_TOUCH: 112 case WLR_INPUT_DEVICE_TOUCH:
108 case WLR_INPUT_DEVICE_TABLET_PAD: 113 case WLR_INPUT_DEVICE_TABLET_PAD: