aboutsummaryrefslogtreecommitdiff
path: root/monsterwm.c
diff options
context:
space:
mode:
authorIvan Kanakarakis <ivan.kanak@gmail.com>2012-08-05 21:04:23 +0300
committerIvan Kanakarakis <ivan.kanak@gmail.com>2012-08-06 11:07:08 +0300
commitaa557f6e5121c3fd1988883be90eb4ee74d76bfa (patch)
tree2c40ca6a18ef36719eb87c88c8c38f9be7df716f /monsterwm.c
parente0f3f9efedf638069cba665435658d0ca10a5ff3 (diff)
on FLOAT mode do not mark tiled clients as floating
this results in instant tiling of non-floating clients when switching mode away from FLOAT. this seems to be more expected. reference: https://bbs.archlinux.org/viewtopic.php?pid=1142030#p1142030
Diffstat (limited to 'monsterwm.c')
-rw-r--r--monsterwm.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/monsterwm.c b/monsterwm.c
index b6d71de..4673e84 100644
--- a/monsterwm.c
+++ b/monsterwm.c
@@ -1070,10 +1070,8 @@ void swap_master(void) {
*/
void switch_mode(const Arg *arg) {
Desktop *d = &desktops[currdeskidx];
- if (d->mode == arg->i && d->mode != FLOAT)
- for (Client *c = d->head; c; c = c->next) c->isfloat = False;
- if ((d->mode = arg->i) == FLOAT)
- for (Client *c = d->head; c; c = c->next) c->isfloat = True;
+ if (d->mode != arg->i) d->mode = arg->i;
+ else if (d->mode != FLOAT) for (Client *c = d->head; c; c = c->next) c->isfloat = False;
if (d->head) { tile(d); focus(d->curr, d); }
desktopinfo();
}