aboutsummaryrefslogtreecommitdiffstats
path: root/sway/input/seat.c
diff options
context:
space:
mode:
authorLibravatar Brian Ashworth <bosrsf04@gmail.com>2019-02-13 23:46:20 -0500
committerLibravatar emersion <contact@emersion.fr>2019-02-14 11:01:08 +0100
commitab42874f71bceeaf0357dbf3020f1cb73fb2c738 (patch)
treea3876a12d29047f178ae3beb59a31d00ee6005f1 /sway/input/seat.c
parentMerge pull request #3675 from RedSoxFan/fix-move-tiling-self (diff)
downloadsway-ab42874f71bceeaf0357dbf3020f1cb73fb2c738.tar.gz
sway-ab42874f71bceeaf0357dbf3020f1cb73fb2c738.tar.zst
sway-ab42874f71bceeaf0357dbf3020f1cb73fb2c738.zip
seat: allow tree focus changes while layer focused
This allows the focused inactive tree node and visible workspaces to be changed while a surface layer has focus. The layer temporarily loses focus, the tree focus changes, and the layer gets refocused.
Diffstat (limited to 'sway/input/seat.c')
-rw-r--r--sway/input/seat.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sway/input/seat.c b/sway/input/seat.c
index 18664d7c..df48b751 100644
--- a/sway/input/seat.c
+++ b/sway/input/seat.c
@@ -725,6 +725,10 @@ void seat_set_raw_focus(struct sway_seat *seat, struct sway_node *node) {
725 725
726void seat_set_focus(struct sway_seat *seat, struct sway_node *node) { 726void seat_set_focus(struct sway_seat *seat, struct sway_node *node) {
727 if (seat->focused_layer) { 727 if (seat->focused_layer) {
728 struct wlr_layer_surface_v1 *layer = seat->focused_layer;
729 seat_set_focus_layer(seat, NULL);
730 seat_set_focus(seat, node);
731 seat_set_focus_layer(seat, layer);
728 return; 732 return;
729 } 733 }
730 734