diff options
author | emersion <contact@emersion.fr> | 2018-07-06 14:37:52 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-06 14:37:52 +0100 |
commit | b8ee88344a5e2869fd3ce04762eda305dc5bf62e (patch) | |
tree | a645930a9b105185a5f2dbddbe8ca8acf50a4559 /sway/input/input-manager.c | |
parent | a06d45a14d1f222a42d23bf1f49bb6995dc3b27b (diff) | |
parent | 3d2595b1028ce1f7cf0ceff673e7180c6c991afb (diff) |
Merge pull request #2220 from ianyfan/remove-input-fix
Attach destroy handler earlier for input devices
Diffstat (limited to 'sway/input/input-manager.c')
-rw-r--r-- | sway/input/input-manager.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sway/input/input-manager.c b/sway/input/input-manager.c index 29b47a7b..98f7d7cf 100644 --- a/sway/input/input-manager.c +++ b/sway/input/input-manager.c @@ -224,6 +224,9 @@ static void handle_new_input(struct wl_listener *listener, void *data) { input_manager_libinput_config_pointer(input_device); } + wl_signal_add(&device->events.destroy, &input_device->device_destroy); + input_device->device_destroy.notify = handle_device_destroy; + struct sway_seat *seat = NULL; if (!input_has_seat_configuration(input)) { wlr_log(L_DEBUG, "no seat configuration, using default seat"); @@ -260,9 +263,6 @@ static void handle_new_input(struct wl_listener *listener, void *data) { "device '%s' is not configured on any seats", input_device->identifier); } - - wl_signal_add(&device->events.destroy, &input_device->device_destroy); - input_device->device_destroy.notify = handle_device_destroy; } static void handle_inhibit_activate(struct wl_listener *listener, void *data) { |