aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sway/layout.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sway/layout.c b/sway/layout.c
index d32f3dd0..d7265605 100644
--- a/sway/layout.c
+++ b/sway/layout.c
@@ -99,6 +99,8 @@ swayc_t *add_sibling(swayc_t *fixed, swayc_t *active) {
list_insert(parent->children, i + 1, active);
}
active->parent = parent;
+ // focus new child
+ parent->focused = active;
return active->parent;
}