[pygtk-1.99.17, gtk+-2.2.4, python-2.3.3]
I am trying to set the drag icon for d&d from a treeview(with liststore).
The d&d works OK with the default icon, but the source row is so large,
it's hard to see where you're dropping it. I want to use some small pixbuf
instead of the image of the source row. When I execute:
pb = gtk.gdk.pixbuf_new_from_xpm_data(openclose.Openclose.plus_xpm_d)
self.tv.drag_source_set_icon_pixbuf(pb)
I get:
(er.py:13439): Gtk-CRITICAL **: file gtkdnd.c: line 2130
(gtk_drag_source_set_icon_pixbuf): assertion `site != NULL' failed
where that source is:
gtk_drag_source_set_icon_pixbuf (GtkWidget *widget, GdkPixbuf *pixbuf)
{ GtkDragSourceSite *site;
g_return_if_fail (GTK_IS_WIDGET (widget));
g_return_if_fail (GDK_IS_PIXBUF (pixbuf));
site = g_object_get_data (G_OBJECT (widget), "gtk-site-data");
g_return_if_fail (site != NULL); // HERE
The drag proceeds with the default icon.
I've tried drag_source_set_icon_stock with the same failure.
Is there any way to change the drag icon for a treeview row?
-- George Young
--
"Are the gods not just?" "Oh no, child.
What would become of us if they were?" (CSL)
_______________________________________________
pygtk mailing list [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/