Configuration file for DWM on MacBook Air
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
481 B

  1. /*
  2. * (C)opyright MMVI Anselm R. Garbe <garbeam at gmail dot com>
  3. * See LICENSE file for license details.
  4. */
  5. #include "wm.h"
  6. #include <X11/keysym.h>
  7. static Key key[] = {
  8. KEYS
  9. };
  10. void
  11. update_keys()
  12. {
  13. unsigned int i, len;
  14. KeyCode code;
  15. len = sizeof(key) / sizeof(key[0]);
  16. for(i = 0; i < len; i++) {
  17. code = XKeysymToKeycode(dpy, key[i].keysym);
  18. XUngrabKey(dpy, code, key[i].mod, root);
  19. XGrabKey(dpy, code, key[i].mod, root, True, GrabModeAsync, GrabModeAsync);
  20. }
  21. }