diff options
author | MC <mc@hack.org> | 2010-06-30 13:58:13 +0200 |
---|---|---|
committer | MC <mc@hack.org> | 2010-06-30 13:58:13 +0200 |
commit | d6c8f311e09a2bb78ffe636d373fb44a61720662 (patch) | |
tree | 83950a46b421950d0b298fbc1eee8e45aafcac85 | |
parent | 127afdd70593b6f33cb38e53545565aa77f3c131 (diff) | |
download | mcwm-d6c8f311e09a2bb78ffe636d373fb44a61720662.zip |
Unfocus before unmapping and only if we have a focus.
-rw-r--r-- | mcwm.c | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -294,6 +294,12 @@ void changeworkspace(int ws) } PDEBUG("Changing from workspace #%d to #%d\n", curws, ws); + + if (NULL != focuswin) + { + setunfocus(focuswin->id); + focuswin = NULL; + } /* Go through list of current ws. Unmap everything that isn't fixed. */ for (item = wslist[curws]; item != NULL; item = item->next) @@ -304,8 +310,6 @@ void changeworkspace(int ws) xcb_unmap_window(conn, client->id); } } - - focuswin = NULL; /* Go through list of new ws. Map everything that isn't fixed. */ for (item = wslist[ws]; item != NULL; item = item->next) |