mirror of
https://github.com/swaywm/sway.git
synced 2026-04-23 06:46:27 -04:00
parent
17ff13fc84
commit
b4a75a1ab2
2 changed files with 14 additions and 4 deletions
|
|
@ -1329,6 +1329,14 @@ void container_detach(struct sway_container *child) {
|
|||
container_update_representation(old_parent);
|
||||
node_set_dirty(&old_parent->node);
|
||||
} else if (old_workspace) {
|
||||
// We may have removed the last tiling child from the workspace. If the
|
||||
// workspace layout was e.g. tabbed, then at this point it may be just
|
||||
// H[]. So, reset it to the default (e.g. T[]) for next time.
|
||||
if (!old_workspace->tiling->length) {
|
||||
old_workspace->layout =
|
||||
output_get_default_layout(old_workspace->output);
|
||||
}
|
||||
|
||||
workspace_update_representation(old_workspace);
|
||||
node_set_dirty(&old_workspace->node);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue