]> git.sur5r.net Git - i3/i3/commitdiff
Bugfix: Update _NET_WM_STATE when clients request changes via ClientMessage
authorMichael Stapelberg <michael@stapelberg.de>
Wed, 26 May 2010 21:11:42 +0000 (23:11 +0200)
committerMichael Stapelberg <michael@stapelberg.de>
Wed, 26 May 2010 21:12:36 +0000 (23:12 +0200)
This fixes problems with Chromium fullscreen mode

src/client.c

index 9c136ca6bc4ba68dfb98095e2f0a766bad960d8c..e2868faf3b21feaabb61ebd6d187fc65a9d10b2b 100644 (file)
@@ -228,6 +228,10 @@ void client_enter_fullscreen(xcb_connection_t *conn, Client *client, bool global
         uint32_t values[] = { XCB_STACK_MODE_ABOVE };
         xcb_configure_window(conn, client->frame, XCB_CONFIG_WINDOW_STACK_MODE, values);
 
+        /* Update _NET_WM_STATE */
+        values[0] = atoms[_NET_WM_STATE_FULLSCREEN];
+        xcb_change_property(conn, XCB_PROP_MODE_REPLACE, client->child, atoms[_NET_WM_STATE], ATOM, 32, 1, values);
+
         fake_configure_notify(conn, r, client->child);
 
         xcb_flush(conn);
@@ -262,6 +266,9 @@ void client_leave_fullscreen(xcb_connection_t *conn, Client *client) {
                 render_layout(conn);
         }
 
+        /* Update _NET_WM_STATE */
+        xcb_change_property(conn, XCB_PROP_MODE_REPLACE, client->child, atoms[_NET_WM_STATE], ATOM, 32, 0, NULL);
+
         xcb_flush(conn);
 }