From fc43ec0bbc414558e31df98475ee6ba57433cab0 Mon Sep 17 00:00:00 2001 From: Benjamin Otte Date: Wed, 19 Feb 2020 04:44:41 +0100 Subject: gtk: Bubble drag events like motion events Emit crossing events - with a new GTK_CROSSING_DROP type - like we do for motion events. There is no more special casing for them. Note that the gesture has not been updated yet, so some obscure behavior may occur. --- gtk/gtkeventcontrollerprivate.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'gtk/gtkeventcontrollerprivate.h') diff --git a/gtk/gtkeventcontrollerprivate.h b/gtk/gtkeventcontrollerprivate.h index e9e17f14e4..571d78f960 100644 --- a/gtk/gtkeventcontrollerprivate.h +++ b/gtk/gtkeventcontrollerprivate.h @@ -24,7 +24,8 @@ typedef enum { GTK_CROSSING_FOCUS, - GTK_CROSSING_POINTER + GTK_CROSSING_POINTER, + GTK_CROSSING_DROP } GtkCrossingType; typedef enum { @@ -47,11 +48,12 @@ typedef struct _GtkCrossingData GtkCrossingData; * @new_descendent: the direct child of the receiving widget that * is an ancestor of @new_target, or %NULL if @new_target is not * a descendent of the receiving widget + * @drop: the #GdkDrop if this is info for a drop operation * * The struct that is passed to gtk_event_controller_handle_crossing(). * * The @old_target and @new_target fields are set to the old or new - * focus or hover location. + * focus, drop or hover location. */ struct _GtkCrossingData { GtkCrossingType type; @@ -61,6 +63,7 @@ struct _GtkCrossingData { GtkWidget *old_descendent; GtkWidget *new_target; GtkWidget *new_descendent; + GdkDrop *drop; }; struct _GtkEventController -- cgit v1.2.1