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, struct sway_seat_node *current; wl_list_for_each(current, &seat->focus_stack, link) { struct sway_node *node = current->node; - if (node_get_parent(node) == parent) { - return node; + if (node_get_parent(node) != parent) { + continue; } + if (parent->type == N_WORKSPACE) { + // Only consider tiling children + struct sway_workspace *ws = parent->sway_workspace; + if (list_find(ws->tiling, node->sway_container) == -1) { + continue; + } + } + return node; } return NULL; } |