diff options
author | David96 <david@hameipe.de> | 2020-04-09 12:33:18 +0200 |
---|---|---|
committer | Simon Ser <contact@emersion.fr> | 2020-04-17 15:49:17 +0200 |
commit | 2b15cf453e4b28324e9012515011a705c2960b30 (patch) | |
tree | 4bfd3c2cc3518597d8df3f70107a39b424432e17 | |
parent | 0efc28e2f58a9a98d219cf2f3a92e18577c9926c (diff) | |
download | sway-2b15cf453e4b28324e9012515011a705c2960b30.tar.xz |
Don't transfer focus to NULL node on touch
Fixes #5185
-rw-r--r-- | sway/input/cursor.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sway/input/cursor.c b/sway/input/cursor.c index 11a2de85..69660945 100644 --- a/sway/input/cursor.c +++ b/sway/input/cursor.c @@ -408,7 +408,9 @@ static void handle_touch_down(struct wl_listener *listener, void *data) { event->touch_id, sx, sy); } - seat_set_focus(seat, focused_node); + if (focused_node) { + seat_set_focus(seat, focused_node); + } } static void handle_touch_up(struct wl_listener *listener, void *data) { |