+ else if (type == EnterNotify || type == LeaveNotify) {
+ printf("enter: %d\n", type);
+ key_t key = EnterNotify ? key_enter : key_leave;
+ if ((win = win_find(dpy,ev->xcrossing.window,0)))
+ wm_handle_key(win, key, MOD(), PTR());
+ }
+ else if (type == FocusIn || type == FocusOut) {
+ printf("focus: %d\n", type);
+ key_t key = FocusIn ? key_focus : key_unfocus;
+ if ((win = win_find(dpy,ev->xfocus.window,0)))
+ wm_handle_key(win, key, MOD(), PTR());
+ }