forked from AuroraMiddleware/gtk
icon-browser: Stop using gtk_drag_source_set_icon_pixbuf
We can just use gtk_drag_source_set_icon_name.
This commit is contained in:
parent
2ac0df0b75
commit
c0d6fd4f86
@ -94,13 +94,9 @@ get_icon (GtkWidget *image, const gchar *name, gint size)
|
||||
static void
|
||||
set_image (GtkWidget *image, const gchar *name, gint size)
|
||||
{
|
||||
GdkPixbuf *pixbuf;
|
||||
|
||||
gtk_image_set_from_icon_name (GTK_IMAGE (image), name);
|
||||
gtk_image_set_pixel_size (GTK_IMAGE (image), size);
|
||||
pixbuf = get_icon (image, name, size);
|
||||
gtk_drag_source_set_icon_pixbuf (image, pixbuf);
|
||||
g_object_unref (pixbuf);
|
||||
gtk_drag_source_set_icon_name (image, name);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -2623,7 +2623,7 @@ gtk_widget_class_init (GtkWidgetClass *klass)
|
||||
*
|
||||
* The ::drag-begin signal is emitted on the drag source when a drag is
|
||||
* started. A typical reason to connect to this signal is to set up a
|
||||
* custom drag icon with e.g. gtk_drag_source_set_icon_pixbuf().
|
||||
* custom drag icon with e.g. gtk_drag_source_set_icon_surface().
|
||||
*
|
||||
* Note that some widgets set up a drag icon in the default handler of
|
||||
* this signal, so you may have to use g_signal_connect_after() to
|
||||
|
Loading…
Reference in New Issue
Block a user