]> git.sur5r.net Git - i3/i3/commitdiff
Ignore notify events which are not in mode XCB_NOTIFY_MODE_NORMAL
authorMichael Stapelberg <michael+x200@stapelberg.de>
Tue, 10 Mar 2009 10:26:52 +0000 (11:26 +0100)
committerMichael Stapelberg <michael+x200@stapelberg.de>
Tue, 10 Mar 2009 10:26:52 +0000 (11:26 +0100)
src/handlers.c

index 8fffcbe12f88edb97c6b6af3aa2659da1a10d8fd..7475cd8f28eb8b6f2d362083a9b450311bf5486f 100644 (file)
@@ -128,6 +128,10 @@ int handle_key_press(void *ignored, xcb_connection_t *conn, xcb_key_press_event_
  */
 int handle_enter_notify(void *ignored, xcb_connection_t *conn, xcb_enter_notify_event_t *event) {
         LOG("enter_notify for %08x, mode = %d, detail %d, serial %d\n", event->event, event->mode, event->detail, event->sequence);
+        if (event->mode != XCB_NOTIFY_MODE_NORMAL) {
+                LOG("This was not a normal notify, ignoring\n");
+                return 1;
+        }
         /* Some events are not interesting, because they were not generated actively by the
            user, but be reconfiguration of windows */
         if (event_is_ignored(event->sequence))