aboutsummaryrefslogtreecommitdiff
path: root/sway/input/seat.c
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2018-04-21 14:44:11 +0200
committerGitHub <noreply@github.com>2018-04-21 14:44:11 +0200
commit7d43cedc95a76cc4d466f76f0023383abd6ddab0 (patch)
tree9fae75ffb8943c72eabb2f17ea96b4ac6826c6bb /sway/input/seat.c
parent8e32c4a1fb287d1a3675f3359891d909dc2b9456 (diff)
parent33ed279494e7f95d74d494523afe8949091da8cd (diff)
Merge pull request #1836 from emersion/workspace-focus-update-cursor
Update cursor when workspace focus changes
Diffstat (limited to 'sway/input/seat.c')
-rw-r--r--sway/input/seat.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/sway/input/seat.c b/sway/input/seat.c
index 8bba7d8f..631a273f 100644
--- a/sway/input/seat.c
+++ b/sway/input/seat.c
@@ -564,6 +564,12 @@ void seat_set_focus_warp(struct sway_seat *seat,
view_set_activated(view, false);
}
+ if (last_workspace && last_workspace != new_workspace) {
+ struct timespec now;
+ clock_gettime(CLOCK_MONOTONIC, &now);
+ cursor_send_pointer_motion(seat->cursor, now.tv_nsec / 1000);
+ }
+
seat->has_focus = (container != NULL);
update_debug_tree();