summaryrefslogtreecommitdiff
path: root/gdk/x11/gdkeventsource.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2019-03-06 23:38:52 -0500
committerMatthias Clasen <mclasen@redhat.com>2019-03-06 23:42:36 -0500
commiteacbeb9efd49e9712df66f95c6f989e252b2b297 (patch)
treec31ad7ba90c3dee02673ae3c2eb0a1e384ca053a /gdk/x11/gdkeventsource.c
parent18da852e15d0d1159da170ccd8c7d8d62233d171 (diff)
downloadgtk+-eacbeb9efd49e9712df66f95c6f989e252b2b297.tar.gz
x11: Don't emit GDK_NOTHING events
They are good for nothing.
Diffstat (limited to 'gdk/x11/gdkeventsource.c')
-rw-r--r--gdk/x11/gdkeventsource.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/gdk/x11/gdkeventsource.c b/gdk/x11/gdkeventsource.c
index 5f85a0b7b0..25c68c3a3e 100644
--- a/gdk/x11/gdkeventsource.c
+++ b/gdk/x11/gdkeventsource.c
@@ -306,6 +306,12 @@ gdk_event_source_translate_event (GdkX11Display *x11_display,
}
if (event &&
+ event->any.type == GDK_NOTHING)
+ {
+ g_clear_object (&event);
+ }
+
+ if (event &&
(event->any.type == GDK_ENTER_NOTIFY ||
event->any.type == GDK_LEAVE_NOTIFY) &&
event->any.surface != NULL)