Reverting the cleanmask change.
authorChristoph Lohmann <20h@r-36.net>
Sun, 14 Oct 2012 05:17:45 +0000 (07:17 +0200)
committerChristoph Lohmann <20h@r-36.net>
Sun, 14 Oct 2012 05:17:45 +0000 (07:17 +0200)
surf.c

diff --git a/surf.c b/surf.c
index 92aff40..56051e9 100644 (file)
--- a/surf.c
+++ b/surf.c
@@ -21,7 +21,6 @@
 #include <sys/file.h>
 
 #define LENGTH(x)               (sizeof x / sizeof x[0])
-#define CLEANMASK(mask)         (mask & (GDK_SHIFT_MASK|GDK_CONTROL_MASK|GDK_MOD1_MASK|GDK_MOD2_MASK|GDK_MOD3_MASK|GDK_MOD4_MASK|GDK_MOD5_MASK))
 
 enum { AtomFind, AtomGo, AtomUri, AtomLast };
 
@@ -381,7 +380,7 @@ keypress(GtkWidget* w, GdkEventKey *ev, Client *c) {
        updatewinid(c);
        for(i = 0; i < LENGTH(keys); i++) {
                if(gdk_keyval_to_lower(ev->keyval) == keys[i].keyval
-                               && CLEANMASK(keys[i].mod) == CLEANMASK(ev->state)
+                               && (ev->state & keys[i].mod) == keys[i].mod
                                && keys[i].func) {
                        keys[i].func(c, &(keys[i].arg));
                        processed = TRUE;