diff options
author | Benjamin Otte <otte@redhat.com> | 2017-11-18 05:53:25 +0100 |
---|---|---|
committer | Benjamin Otte <otte@redhat.com> | 2017-11-20 23:12:33 +0100 |
commit | d6a209816bacff89e361a580b24e847dca0bdef5 (patch) | |
tree | a95d06515b9513c6d7f2110ddedda19badf26a2b /gtk/gtkdragdest.c | |
parent | 9a6ec4e9591df1a8ed72bbf8793091a1f325b5ff (diff) | |
download | gtk+-d6a209816bacff89e361a580b24e847dca0bdef5.tar.gz |
gdkdnd: Make GdkDragContext->formats a GdkContentFormats
Instead of it being a GList of GdkAtoms.
Diffstat (limited to 'gtk/gtkdragdest.c')
-rw-r--r-- | gtk/gtkdragdest.c | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/gtk/gtkdragdest.c b/gtk/gtkdragdest.c index cd9ee3c5f4..91afffba79 100644 --- a/gtk/gtkdragdest.c +++ b/gtk/gtkdragdest.c @@ -411,8 +411,6 @@ gtk_drag_dest_find_target (GtkWidget *widget, GdkDragContext *context, GdkContentFormats *target_list) { - GdkContentFormats *source_list; - GList *tmp_source; GdkAtom result; g_return_val_if_fail (GTK_IS_WIDGET (widget), NULL); @@ -424,17 +422,8 @@ gtk_drag_dest_find_target (GtkWidget *widget, if (target_list == NULL) return NULL; - source_list = gdk_content_formats_new (NULL, 0); - for (tmp_source = gdk_drag_context_list_targets (context); - tmp_source != NULL; - tmp_source = tmp_source->next) - { - gdk_content_formats_add (source_list, tmp_source->data); - } - - result = gdk_content_formats_intersects (target_list, source_list); - - gdk_content_formats_unref (source_list); + result = gdk_content_formats_intersects (target_list, + gdk_drag_context_get_formats (context)); return result; } |