[gtk+/wip/carlosg/private-event-structs] gesture single: Use GdkEvent API



commit 43793094a51654b1f4581477eb379918826179e5
Author: Matthias Clasen <mclasen redhat com>
Date:   Sat Aug 26 10:52:45 2017 -0400

    gesture single: Use GdkEvent API

 gtk/gtkgesturesingle.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkgesturesingle.c b/gtk/gtkgesturesingle.c
index edf13c7..d0a624e 100644
--- a/gtk/gtkgesturesingle.c
+++ b/gtk/gtkgesturesingle.c
@@ -140,6 +140,7 @@ gtk_gesture_single_handle_event (GtkEventController *controller,
   guint button = 0, state, i;
   gboolean retval, test_touchscreen = FALSE;
   GdkEventType event_type;
+  gboolean emulating;
 
   source_device = gdk_event_get_source_device (event);
 
@@ -159,7 +160,8 @@ gtk_gesture_single_handle_event (GtkEventController *controller,
     case GDK_TOUCH_BEGIN:
     case GDK_TOUCH_END:
     case GDK_TOUCH_UPDATE:
-      if (priv->exclusive && !event->touch.emulating_pointer)
+      gdk_event_get_touch_emulating_pointer (event, &emulating);
+      if (priv->exclusive && !emulating)
         return FALSE;
 
       sequence = gdk_event_get_event_sequence (event);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]