Minor patch to gtkdnd



The guppi component has been generating warnings stemming from
attempting to disconnect the destruction signal from the drop site
handler.  Looking at the code it seemed as if the signal was being
removed but the old site was being left in the widget's datalist.
This patch (against CVS gtk-1-2) attempts to fix that.

Thanks
    Jody
Index: gtk/gtkdnd.c
===================================================================
RCS file: /cvs/gnome/gtk+/gtk/gtkdnd.c,v
retrieving revision 1.37.2.10
diff -u -w -r1.37.2.10 gtkdnd.c
--- gtk/gtkdnd.c	2000/06/11 18:02:31	1.37.2.10
+++ gtk/gtkdnd.c	2000/10/19 01:46:28
@@ -856,9 +856,7 @@
   g_return_if_fail (widget != NULL);
 
   /* HACK, do this in the destroy */
-  site = gtk_object_get_data (GTK_OBJECT (widget), "gtk-drag-dest");
-  if (site)
-    gtk_signal_disconnect_by_data (GTK_OBJECT (widget), site);
+  gtk_drag_dest_unset (widget);
 
   if (GTK_WIDGET_REALIZED (widget))
     gtk_drag_dest_realized (widget);
@@ -906,9 +904,7 @@
   g_return_if_fail (widget != NULL);
 
   /* HACK, do this in the destroy */
-  site = gtk_object_get_data (GTK_OBJECT (widget), "gtk-drag-dest");
-  if (site)
-    gtk_signal_disconnect_by_data (GTK_OBJECT (widget), site);
+  gtk_drag_dest_unset (widget);
 
   if (GTK_WIDGET_REALIZED (widget))
     gtk_drag_dest_realized (widget);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]