Fix up managed dnd

Since commit 6c56d04cee,
we were doing some calls twice in the managed dnd case,
leading to double drops.
This commit is contained in:
Matthias Clasen 2017-11-11 07:46:59 -05:00
parent af13d474e8
commit f40b3bc5bc

View File

@ -1905,7 +1905,9 @@ gtk_drag_drop (GtkDragSourceInfo *info,
if (info->icon_window)
gtk_widget_hide (info->icon_window);
gdk_drag_drop (info->context, time);
if (!gtk_drag_is_managed (info->widget))
gdk_drag_drop (info->context, time);
info->drop_timeout = gdk_threads_add_timeout (DROP_ABORT_TIME,
gtk_drag_abort_timeout,
info);
@ -2195,7 +2197,8 @@ gtk_drag_cancel_internal (GtkDragSourceInfo *info,
guint32 time)
{
gtk_drag_end (info, time);
gdk_drag_abort (info->context, time);
if (!gtk_drag_is_managed (info->widget))
gdk_drag_abort (info->context, time);
gtk_drag_drop_finished (info, result, time);
}