From: Michael Stapelberg Date: Sun, 29 Jan 2012 18:02:48 +0000 (+0000) Subject: Merge branch 'master' into next X-Git-Tag: 4.2~99 X-Git-Url: https://git.sur5r.net/?p=i3%2Fi3;a=commitdiff_plain;h=36464c7a546cb8541d55157bf7dd89aea8645a94;hp=29aa28b623543b20d55f6ddec77fda52dd925c90 Merge branch 'master' into next --- diff --git a/src/randr.c b/src/randr.c index 5cbca9f6..ae181a91 100644 --- a/src/randr.c +++ b/src/randr.c @@ -758,7 +758,8 @@ void randr_query_outputs() { DLOG("next = %p\n", next); } - /* 2: iterate through workspaces and re-assign them */ + /* 2: iterate through workspaces and re-assign them, fixing the coordinates + * of floating containers as we go */ Con *current; Con *old_content = output_get_content(output->con); while (!TAILQ_EMPTY(&(old_content->nodes_head))) { @@ -767,6 +768,10 @@ void randr_query_outputs() { con_detach(current); DLOG("Re-attaching current = %p / %s\n", current, current->name); con_attach(current, first_content, false); + DLOG("Fixing the coordinates of floating containers\n"); + Con *floating_con; + TAILQ_FOREACH(floating_con, &(current->floating_head), floating_windows) + floating_fix_coordinates(floating_con, &(old_content->rect), &(first_content->rect)); DLOG("Done, next\n"); } DLOG("re-attached all workspaces\n");