This commit is contained in:
Baltazár Radics 2025-03-25 17:55:24 +00:00 committed by GitHub
commit 95583b37e8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 5 additions and 2 deletions

View file

@ -121,6 +121,9 @@ void workspace_detach(struct sway_workspace *workspace);
struct sway_container *workspace_add_tiling(struct sway_workspace *workspace,
struct sway_container *con);
void workspace_attach_tiling(struct sway_workspace *ws,
struct sway_container *con);
void workspace_add_floating(struct sway_workspace *workspace,
struct sway_container *con);

View file

@ -221,7 +221,7 @@ static void container_move_to_workspace(struct sway_container *container,
} else {
container_detach(container);
if (workspace_is_empty(workspace) && container->pending.children) {
workspace_unwrap_children(workspace, container);
workspace_attach_tiling(workspace, container);
} else {
container->pending.width = container->pending.height = 0;
container->width_fraction = container->height_fraction = 0;

View file

@ -740,7 +740,7 @@ static void set_workspace(struct sway_container *container, void *data) {
container->pending.workspace = container->pending.parent->pending.workspace;
}
static void workspace_attach_tiling(struct sway_workspace *ws,
void workspace_attach_tiling(struct sway_workspace *ws,
struct sway_container *con) {
list_add(ws->tiling, con);
con->pending.workspace = ws;