diff options
Diffstat (limited to 'tag.c')
| -rw-r--r-- | tag.c | 9 |
1 files changed, 6 insertions, 3 deletions
| @@ -106,7 +106,8 @@ settags(Client *c) | |||
| 106 | if(!matched) | 106 | if(!matched) |
| 107 | for(i = 0; i < ntags; i++) | 107 | for(i = 0; i < ntags; i++) |
| 108 | c->tags[i] = seltag[i]; | 108 | c->tags[i] = seltag[i]; |
| 109 | for(c->weight = 0; c->weight < ntags && !c->tags[c->weight]; c->weight++); | 109 | if(!c->isfloat) |
| 110 | for(c->weight = 0; c->weight < ntags && !c->tags[c->weight]; c->weight++); | ||
| 110 | } | 111 | } |
| 111 | 112 | ||
| 112 | void | 113 | void |
| @@ -120,7 +121,8 @@ tag(Arg *arg) | |||
| 120 | for(i = 0; i < ntags; i++) | 121 | for(i = 0; i < ntags; i++) |
| 121 | sel->tags[i] = False; | 122 | sel->tags[i] = False; |
| 122 | sel->tags[arg->i] = True; | 123 | sel->tags[arg->i] = True; |
| 123 | sel->weight = arg->i; | 124 | if(!sel->isfloat) |
| 125 | sel->weight = arg->i; | ||
| 124 | arrange(NULL); | 126 | arrange(NULL); |
| 125 | } | 127 | } |
| 126 | 128 | ||
| @@ -136,6 +138,7 @@ toggletag(Arg *arg) | |||
| 136 | for(i = 0; i < ntags && !sel->tags[i]; i++); | 138 | for(i = 0; i < ntags && !sel->tags[i]; i++); |
| 137 | if(i == ntags) | 139 | if(i == ntags) |
| 138 | sel->tags[arg->i] = True; | 140 | sel->tags[arg->i] = True; |
| 139 | sel->weight = (i == ntags) ? arg->i : i; | 141 | if(!sel->isfloat) |
| 142 | sel->weight = (i == ntags) ? arg->i : i; | ||
| 140 | arrange(NULL); | 143 | arrange(NULL); |
| 141 | } | 144 | } |
