dwm-meillo

diff tag.c @ 440:9d73c8298b2e

maybe this might work
author Anselm R. Garbe <arg@10kloc.org>
date Wed, 06 Sep 2006 13:56:46 +0200
parents a230e4432bb7
children 785bad5f21dd
line diff
     1.1 --- a/tag.c	Wed Sep 06 12:19:07 2006 +0200
     1.2 +++ b/tag.c	Wed Sep 06 13:56:46 2006 +0200
     1.3 @@ -110,7 +110,8 @@
     1.4  	if(!matched)
     1.5  		for(i = 0; i < ntags; i++)
     1.6  			c->tags[i] = seltag[i];
     1.7 -	for(c->weight = 0; c->weight < ntags && !c->tags[c->weight]; c->weight++);
     1.8 +	if(!c->isfloat)
     1.9 +		for(c->weight = 0; c->weight < ntags && !c->tags[c->weight]; c->weight++);
    1.10  }
    1.11  
    1.12  void
    1.13 @@ -124,7 +125,8 @@
    1.14  	for(i = 0; i < ntags; i++)
    1.15  		sel->tags[i] = False;
    1.16  	sel->tags[arg->i] = True;
    1.17 -	sel->weight = arg->i;
    1.18 +	if(!sel->isfloat)
    1.19 +		sel->weight = arg->i;
    1.20  	arrange(NULL);
    1.21  }
    1.22  
    1.23 @@ -140,6 +142,7 @@
    1.24  	for(i = 0; i < ntags && !sel->tags[i]; i++);
    1.25  	if(i == ntags)
    1.26  		sel->tags[arg->i] = True;
    1.27 -	sel->weight = (i == ntags) ? arg->i : i;
    1.28 +	if(!sel->isfloat)
    1.29 +		sel->weight = (i == ntags) ? arg->i : i;
    1.30  	arrange(NULL);
    1.31  }