]> git.sur5r.net Git - i3/i3/commitdiff
Bugfix: Fix two bugs in fullscreen mode
authorMichael Stapelberg <michael+git@stapelberg.de>
Sat, 28 Feb 2009 00:01:06 +0000 (01:01 +0100)
committerMichael Stapelberg <michael+git@stapelberg.de>
Sat, 28 Feb 2009 00:01:06 +0000 (01:01 +0100)
src/util.c

index f68c9797933c1997b1f988aacb56c2be695b6472..a25e63763d191114b188be02264839e60f81d592 100644 (file)
@@ -256,13 +256,17 @@ void toggle_fullscreen(xcb_connection_t *conn, Client *client) {
                 printf("child itself will be at %dx%d with size %dx%d\n",
                                 values[0], values[1], values[2], values[3]);
 
+                xcb_configure_window(conn, client->frame, mask, values);
+
+                /* Child’s coordinates are relative to the parent (=frame) */
+                values[0] = 0;
+                values[1] = 0;
+                xcb_configure_window(conn, client->child, mask, values);
+
                 /* Raise the window */
                 values[0] = XCB_STACK_MODE_ABOVE;
                 xcb_configure_window(conn, client->frame, XCB_CONFIG_WINDOW_STACK_MODE, values);
 
-                xcb_configure_window(conn, client->frame, mask, values);
-                xcb_configure_window(conn, client->child, mask, values);
-
                 xcb_flush(conn);
         } else {
                 printf("leaving fullscreen mode\n");