Got questions, comments, patches, etc.?
Contact Jason Woofenden
gitweb
/
dwm.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
applied sanders patch
[dwm.git]
/
event.c
diff --git
a/event.c
b/event.c
index
bdf4071
..
a719bf2
100644
(file)
--- a/
event.c
+++ b/
event.c
@@
-109,10
+109,20
@@
buttonpress(XEvent *e)
for(a.i = 0; a.i < ntags; a.i++) {
x += textw(tags[a.i]);
if(ev->x < x) {
for(a.i = 0; a.i < ntags; a.i++) {
x += textw(tags[a.i]);
if(ev->x < x) {
- if(ev->button == Button1)
- view(&a);
- else if(ev->button == Button3)
- toggleview(&a);
+ switch(ev->button) {
+ case Button1:
+ if(ev->state & MODKEY)
+ tag(&a);
+ else
+ view(&a);
+ break;
+ case Button3:
+ if(ev->state & MODKEY)
+ toggletag(&a);
+ else
+ toggleview(&a);
+ break;
+ }
return;
}
}
return;
}
}