Introduction
Introduction Statistics Contact Development Disclaimer Help
tfixing numlock bug. - surf - customized build of surf, the suckless webkit bro…
git clone git://src.adamsgaard.dk/surf
Log
Files
Refs
README
LICENSE
---
commit 38d809ce59fd4e7f041de3851be27f5a08278cf9
parent 4dbf90e0d7846bfdfa93564b6ec85068367f2008
Author: Enno Boland (tox) <[email protected]>
Date: Mon, 7 Sep 2009 15:43:18 +0200
fixing numlock bug.
Diffstat:
M surf.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/surf.c b/surf.c
t@@ -17,6 +17,7 @@
#include <glib/gstdio.h>
#define LENGTH(x) (sizeof x / sizeof x[0])
+#define CLEANMASK(mask) (mask & ~(GDK_MOD2_MASK))
Display *dpy;
Atom urlprop;
t@@ -276,7 +277,8 @@ keypress(GtkWidget* w, GdkEventKey *ev, Client *c) {
focus = BROWSER;
for(i = 0; i < LENGTH(keys); i++) {
if(focus & keys[i].focus && ev->keyval == keys[i].keyval &&
- (ev->state == keys[i].mod || ev->state & keys[…
+ (CLEANMASK(ev->state) == keys[i].mod ||
+ CLEANMASK(ev->state) & keys[i].mod)
&& keys[i].func) {
keys[i].func(c, &(keys[i].arg));
processed = TRUE;
You are viewing proxied material from mx1.adamsgaard.dk. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.