From: Michael Stapelberg Date: Wed, 3 Mar 2010 08:32:31 +0000 (+0100) Subject: Update fullscreen client position/size when an output changes (Thanks Merovius) X-Git-Tag: 3.e~6^2~124 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=3cfe1b35e0b4ac3a0a83eb631bd0243c42081684;p=i3%2Fi3 Update fullscreen client position/size when an output changes (Thanks Merovius) This fixes #187. --- diff --git a/src/randr.c b/src/randr.c index cc9efb25..500ce5d5 100644 --- a/src/randr.c +++ b/src/randr.c @@ -252,6 +252,18 @@ static void output_change_mode(xcb_connection_t *conn, Output *output) { SLIST_FOREACH(client, &(ws->focus_stack), focus_clients) client->force_reconfigure = true; + + /* Update the dimensions of a fullscreen client, if any */ + if (ws->fullscreen_client != NULL) { + DLOG("Updating fullscreen client size\n"); + client = ws->fullscreen_client; + Rect r = ws->rect; + xcb_set_window_rect(conn, client->frame, r); + + r.x = 0; + r.y = 0; + xcb_set_window_rect(conn, client->child, r); + } } }