diff options
Diffstat (limited to 'sway')
-rw-r--r-- | sway/input/seat.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/sway/input/seat.c b/sway/input/seat.c index ab5047b2..6d02970d 100644 --- a/sway/input/seat.c +++ b/sway/input/seat.c | |||
@@ -888,9 +888,17 @@ struct sway_node *seat_get_active_child(struct sway_seat *seat, | |||
888 | struct sway_seat_node *current; | 888 | struct sway_seat_node *current; |
889 | wl_list_for_each(current, &seat->focus_stack, link) { | 889 | wl_list_for_each(current, &seat->focus_stack, link) { |
890 | struct sway_node *node = current->node; | 890 | struct sway_node *node = current->node; |
891 | if (node_get_parent(node) == parent) { | 891 | if (node_get_parent(node) != parent) { |
892 | return node; | 892 | continue; |
893 | } | 893 | } |
894 | if (parent->type == N_WORKSPACE) { | ||
895 | // Only consider tiling children | ||
896 | struct sway_workspace *ws = parent->sway_workspace; | ||
897 | if (list_find(ws->tiling, node->sway_container) == -1) { | ||
898 | continue; | ||
899 | } | ||
900 | } | ||
901 | return node; | ||
894 | } | 902 | } |
895 | return NULL; | 903 | return NULL; |
896 | } | 904 | } |