Send configure notify after putting a client into fullscreen mode, log at a central place

This commit is contained in:
Michael Stapelberg 2009-03-14 17:37:11 +01:00
parent 29112655dc
commit 80e2bf708d
3 changed files with 5 additions and 3 deletions

View File

@ -455,9 +455,6 @@ int handle_configure_request(void *prophs, xcb_connection_t *conn, xcb_configure
fake_configure_notify(conn, client->child_rect, client->child); fake_configure_notify(conn, client->child_rect, client->child);
LOG("Told the client to stay at %dx%d with size %dx%d\n",
client->child_rect.x, client->child_rect.y, client->child_rect.width, client->child_rect.height);
return 1; return 1;
} }

View File

@ -377,6 +377,9 @@ void toggle_fullscreen(xcb_connection_t *conn, Client *client) {
values[0] = XCB_STACK_MODE_ABOVE; values[0] = XCB_STACK_MODE_ABOVE;
xcb_configure_window(conn, client->frame, XCB_CONFIG_WINDOW_STACK_MODE, values); xcb_configure_window(conn, client->frame, XCB_CONFIG_WINDOW_STACK_MODE, values);
Rect child_rect = workspace->rect;
child_rect.x = child_rect.y = 0;
fake_configure_notify(conn, child_rect, client->child);
} else { } else {
LOG("leaving fullscreen mode\n"); LOG("leaving fullscreen mode\n");
/* Because the coordinates of the window havent changed, it would not be /* Because the coordinates of the window havent changed, it would not be

View File

@ -206,4 +206,6 @@ void fake_configure_notify(xcb_connection_t *conn, Rect r, xcb_window_t window)
xcb_send_event(conn, false, window, XCB_EVENT_MASK_STRUCTURE_NOTIFY, (char*)&generated_event); xcb_send_event(conn, false, window, XCB_EVENT_MASK_STRUCTURE_NOTIFY, (char*)&generated_event);
xcb_flush(conn); xcb_flush(conn);
LOG("Told the client it is at %dx%d with %dx%d\n", r.x, r.y, r.width, r.height);
} }