[wmfs.c] Fix tag 0 bug
This commit is contained in:
11
wmfs.c
11
wmfs.c
@@ -879,6 +879,9 @@ tag(char *cmd)
|
|||||||
{
|
{
|
||||||
int tmp = atoi(cmd);
|
int tmp = atoi(cmd);
|
||||||
|
|
||||||
|
if(!tmp)
|
||||||
|
tmp = 1;
|
||||||
|
|
||||||
if(cmd[0] == '+' || cmd[0] == '-')
|
if(cmd[0] == '+' || cmd[0] == '-')
|
||||||
{
|
{
|
||||||
if(tmp + seltag < 1
|
if(tmp + seltag < 1
|
||||||
@@ -906,6 +909,10 @@ tagtransfert(char *cmd)
|
|||||||
|
|
||||||
if(!sel)
|
if(!sel)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if(!n)
|
||||||
|
n = 1;
|
||||||
|
|
||||||
sel->tag = n;
|
sel->tag = n;
|
||||||
arrange();
|
arrange();
|
||||||
}
|
}
|
||||||
@@ -1304,6 +1311,10 @@ main(int argc,char **argv)
|
|||||||
updatebar();
|
updatebar();
|
||||||
getevent();
|
getevent();
|
||||||
updateall();
|
updateall();
|
||||||
|
printf("X :");
|
||||||
|
debug(event.xbutton.x);
|
||||||
|
printf("T :");
|
||||||
|
debug(seltag);
|
||||||
}
|
}
|
||||||
|
|
||||||
XCloseDisplay(dpy);
|
XCloseDisplay(dpy);
|
||||||
|
|||||||
Reference in New Issue
Block a user