gtk+ r21785 - in trunk: . gtk
- From: rhult svn gnome org
- To: svn-commits-list gnome org
- Subject: gtk+ r21785 - in trunk: . gtk
- Date: Wed, 12 Nov 2008 15:39:34 +0000 (UTC)
Author: rhult
Date: Wed Nov 12 15:39:33 2008
New Revision: 21785
URL: http://svn.gnome.org/viewvc/gtk+?rev=21785&view=rev
Log:
2008-11-12 Richard Hult <richard imendio com>
* gtk/gtkdnd-quartz.c: (gtk_drag_set_icon_pixmap): Implement,
patch from Paul Davis.
Modified:
trunk/ChangeLog
trunk/gtk/gtkdnd-quartz.c
Modified: trunk/gtk/gtkdnd-quartz.c
==============================================================================
--- trunk/gtk/gtkdnd-quartz.c (original)
+++ trunk/gtk/gtkdnd-quartz.c Wed Nov 12 15:39:33 2008
@@ -1668,7 +1668,20 @@
gint hot_x,
gint hot_y)
{
- g_warning ("gtk_drag_set_icon_pixmap is not supported on Mac OS X");
+ GdkPixbuf *pixbuf;
+
+ g_return_if_fail (GDK_IS_DRAG_CONTEXT (context));
+ g_return_if_fail (context->is_source);
+ g_return_if_fail (GDK_IS_COLORMAP (colormap));
+ g_return_if_fail (GDK_IS_PIXMAP (pixmap));
+
+ pixbuf = gdk_pixbuf_get_from_drawable (NULL, pixmap, colormap,
+ 0, 0, /* src */
+ 0, 0, /* dst */
+ -1, -1);
+
+ gtk_drag_set_icon_pixbuf (context, pixbuf, hot_x, hot_y);
+ g_object_unref (pixbuf);
}
/**
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]