From c82378ea578eeed3ea4676443fb761812336f8bb Mon Sep 17 00:00:00 2001 From: Benjamin Otte Date: Mon, 20 Nov 2017 15:58:17 +0100 Subject: gdk: Add GType support to GdkContentFormats This is not used by anything yet, but add it now, so people looking at this new code can make sense of it. Plus, the documentation mentions it, so better have the docs make sense. It will be used once we add support for conversions to GDK and allow doing cipboard/dnd by GValue. --- gtk/gtkdragdest.c | 6 ++++-- gtk/gtktextview.c | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) (limited to 'gtk') diff --git a/gtk/gtkdragdest.c b/gtk/gtkdragdest.c index 9c37569fb1..8b9fbff74f 100644 --- a/gtk/gtkdragdest.c +++ b/gtk/gtkdragdest.c @@ -422,8 +422,10 @@ gtk_drag_dest_find_target (GtkWidget *widget, if (target_list == NULL) return NULL; - result = gdk_content_formats_match (target_list, - gdk_drag_context_get_formats (context)); + gdk_content_formats_match (target_list, + gdk_drag_context_get_formats (context), + NULL, + &result); return result; } diff --git a/gtk/gtktextview.c b/gtk/gtktextview.c index a4bf36d5d6..3f24ec459b 100644 --- a/gtk/gtktextview.c +++ b/gtk/gtktextview.c @@ -8150,7 +8150,7 @@ gtk_text_view_drag_data_received (GtkWidget *widget, GdkAtom *atoms; gint n_atoms; GdkContentFormats *dnd_formats, *buffer_formats; - GdkAtom target = NULL; + const char *target = NULL; copy_tags = FALSE; @@ -8158,7 +8158,7 @@ gtk_text_view_drag_data_received (GtkWidget *widget, buffer_formats = gdk_content_formats_new (atoms, n_atoms); dnd_formats = gdk_drag_context_get_formats (context); - target = gdk_content_formats_match (dnd_formats, buffer_formats); + gdk_content_formats_match (dnd_formats, buffer_formats, NULL, &target); gdk_content_formats_unref (buffer_formats); g_free (atoms); -- cgit v1.2.1