forked from AuroraMiddleware/gtk
Merge branch 'wip/carlosg/issue-1159' into 'master'
Fix issue 1159 Closes #1159 See merge request GNOME/gtk!202
This commit is contained in:
commit
87532f0ac3
@ -698,9 +698,6 @@ gtk_gesture_handle_event (GtkEventController *controller,
|
||||
{
|
||||
gboolean was_claimed;
|
||||
|
||||
was_claimed =
|
||||
gtk_gesture_get_sequence_state (gesture, sequence) == GTK_EVENT_SEQUENCE_CLAIMED;
|
||||
|
||||
if (_gtk_gesture_update_point (gesture, event, FALSE))
|
||||
{
|
||||
if (was_recognized &&
|
||||
@ -710,6 +707,9 @@ gtk_gesture_handle_event (GtkEventController *controller,
|
||||
_gtk_gesture_remove_point (gesture, event);
|
||||
}
|
||||
|
||||
was_claimed =
|
||||
gtk_gesture_get_sequence_state (gesture, sequence) == GTK_EVENT_SEQUENCE_CLAIMED;
|
||||
|
||||
return was_claimed && was_recognized;
|
||||
}
|
||||
else if (event_type == GDK_MOTION_NOTIFY ||
|
||||
|
@ -2503,12 +2503,20 @@ _gtk_widget_emulate_press (GtkWidget *widget,
|
||||
{
|
||||
GtkWidget *event_widget, *next_child, *parent;
|
||||
GdkEvent *press;
|
||||
gdouble x, y;
|
||||
|
||||
event_widget = gtk_get_event_target ((GdkEvent *) event);
|
||||
|
||||
if (event_widget == widget)
|
||||
return;
|
||||
|
||||
gdk_event_get_coords (event, &x, &y);
|
||||
gtk_widget_translate_coordinatesf (event_widget,
|
||||
gtk_widget_get_toplevel (event_widget),
|
||||
x, y,
|
||||
&x, &y);
|
||||
gdk_event_set_coords (event, x, y);
|
||||
|
||||
if (event->any.type == GDK_TOUCH_BEGIN ||
|
||||
event->any.type == GDK_TOUCH_UPDATE ||
|
||||
event->any.type == GDK_TOUCH_END)
|
||||
|
Loading…
Reference in New Issue
Block a user