]> code.delx.au - spectrwm/commitdiff
Prevent possible focus change on release of a pointer grab.
authorReginald Kennedy <rk@rejii.com>
Tue, 18 Nov 2014 03:20:38 +0000 (11:20 +0800)
committerReginald Kennedy <rk@rejii.com>
Tue, 18 Nov 2014 03:36:26 +0000 (11:36 +0800)
spectrwm.c

index fe6868495d01b4412f98756a88ad4a500da9bc98..30ee09fc972e19900220b241057a3868aec9d8f8 100644 (file)
@@ -9615,6 +9615,12 @@ enternotify(xcb_enter_notify_event_t *e)
                return;
        }
 
+       if (focus_mode != SWM_FOCUS_FOLLOW &&
+           e->mode == XCB_NOTIFY_MODE_UNGRAB) {
+               DNPRINTF(SWM_D_EVENT, "enternotify: ungrab; ignoring.\n");
+               return;
+       }
+
        last_event_time = e->time;
 
        if ((win = find_window(e->event)) == NULL) {