diff options
Diffstat (limited to 'sway')
-rw-r--r-- | sway/desktop/render.c | 6 | ||||
-rw-r--r-- | sway/desktop/transaction.c | 1 | ||||
-rw-r--r-- | sway/tree/container.c | 3 |
3 files changed, 6 insertions, 4 deletions
diff --git a/sway/desktop/render.c b/sway/desktop/render.c index cdac9c72..6e1e31f0 100644 --- a/sway/desktop/render.c +++ b/sway/desktop/render.c @@ -266,7 +266,7 @@ static void render_view(struct sway_output *output, pixman_region32_t *damage, render_view_toplevels(view, output, damage, view->swayc->alpha); } - if (view->using_csd) { + if (view->swayc->current.using_csd) { return; } @@ -585,7 +585,7 @@ static void render_container_simple(struct sway_output *output, marks_texture = view->marks_unfocused; } - if (!view->using_csd) { + if (!view->swayc->current.using_csd) { if (state->border == B_NORMAL) { render_titlebar(output, damage, child, state->swayc_x, state->swayc_y, state->swayc_width, colors, @@ -777,7 +777,7 @@ static void render_floating_container(struct sway_output *soutput, marks_texture = view->marks_unfocused; } - if (!view->using_csd) { + if (!view->swayc->current.using_csd) { if (con->current.border == B_NORMAL) { render_titlebar(soutput, damage, con, con->current.swayc_x, con->current.swayc_y, con->current.swayc_width, colors, diff --git a/sway/desktop/transaction.c b/sway/desktop/transaction.c index c08730ce..e89f01d8 100644 --- a/sway/desktop/transaction.c +++ b/sway/desktop/transaction.c @@ -107,6 +107,7 @@ static void copy_pending_state(struct sway_container *container, state->border_left = view->border_left; state->border_right = view->border_right; state->border_bottom = view->border_bottom; + state->using_csd = view->using_csd; } else if (container->type == C_WORKSPACE) { state->ws_fullscreen = container->sway_workspace->fullscreen; state->ws_floating = container->sway_workspace->floating; diff --git a/sway/tree/container.c b/sway/tree/container.c index eb06edc2..db780270 100644 --- a/sway/tree/container.c +++ b/sway/tree/container.c @@ -1030,12 +1030,13 @@ void container_set_floating(struct sway_container *container, bool enable) { struct sway_container *workspace = container_parent(container, C_WORKSPACE); if (enable) { - container_remove_child(container); + struct sway_container *old_parent = container_remove_child(container); container_add_child(workspace->sway_workspace->floating, container); container_init_floating(container); if (container->type == C_VIEW) { view_set_tiled(container->sway_view, false); } + container_reap_empty(old_parent); } else { // Returning to tiled if (container->scratchpad) { |