Bugfix: Don’t redistribute resize percentage values when closing floating (!) windows (Thanks Merovius) (+testcase)

This commit is contained in:
Michael Stapelberg
2010-12-30 02:39:14 +01:00
parent 307c59bde6
commit f65e4f5b16
2 changed files with 43 additions and 1 deletions

View File

@ -180,7 +180,11 @@ void tree_close(Con *con, bool kill_window, bool dont_kill_parent) {
x_con_kill(con);
con_detach(con);
con_fix_percent(parent, WINDOW_REMOVE);
if (con->type != CT_FLOATING_CON) {
/* If the container is *not* floating, we might need to re-distribute
* percentage values for the resized containers. */
con_fix_percent(parent, WINDOW_REMOVE);
}
if (con_is_floating(con)) {
DLOG("Container was floating, killing floating container\n");