Don’t overwrite existing windows with placeholder windows

This could happen when you appended a layout on a workspace where there
are already other windows.
This commit is contained in:
Michael Stapelberg 2014-04-18 20:36:56 +02:00
parent 524f20b8a0
commit 110b8d9557
1 changed files with 2 additions and 1 deletions

View File

@ -181,7 +181,8 @@ static void update_placeholder_contents(placeholder_state *state) {
} }
static void open_placeholder_window(Con *con) { static void open_placeholder_window(Con *con) {
if (con_is_leaf(con)) { if (con_is_leaf(con) &&
(con->window == NULL || con->window->id == XCB_NONE)) {
xcb_window_t placeholder = create_window( xcb_window_t placeholder = create_window(
restore_conn, restore_conn,
con->rect, con->rect,