From 68c1e9e6fcdbf71270eb9612650b4100f940f87d Mon Sep 17 00:00:00 2001 From: Michael Cardell Widerkrantz Date: Sat, 19 Feb 2011 01:48:43 +0100 Subject: Specifically grab the keycodes we bind. --- mcwm.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'mcwm.c') diff --git a/mcwm.c b/mcwm.c index 98cf1bd..6b94d21 100644 --- a/mcwm.c +++ b/mcwm.c @@ -1019,7 +1019,11 @@ int setupkeys(void) return -1; } - } + + /* Grab this key. */ + xcb_grab_key(conn, 1, screen->root, MODKEY, keys[i].keycode, + XCB_GRAB_MODE_ASYNC, XCB_GRAB_MODE_ASYNC); + } /* for */ /* Get rid of the key symbols table. */ free(keysyms); @@ -3102,10 +3106,7 @@ int main(int argc, char **argv) exit(1); } - /* Grab some keys and mouse buttons. */ - - xcb_grab_key(conn, 1, root, MODKEY, XCB_NO_SYMBOL, - XCB_GRAB_MODE_ASYNC, XCB_GRAB_MODE_ASYNC); + /* Grab mouse buttons. */ xcb_grab_button(conn, 0, root, XCB_EVENT_MASK_BUTTON_PRESS | XCB_EVENT_MASK_BUTTON_RELEASE, -- cgit v1.2.3