From bug 312967 [1]:

"When you open the dekstop's Trash icon's property page, you'll see the
usual, and an icon on the top left. If you drag an icon to the default
trash icon, it changes it, but there is no way of removing the new icon
and going back to the default theme."

Proposed patch attached.

[1] http://bugzilla.gnome.org/show_bug.cgi?id=312967

-- 
Christian Neumair <[EMAIL PROTECTED]>

Index: src/file-manager/fm-properties-window.c
===================================================================
RCS file: /cvs/gnome/nautilus/src/file-manager/fm-properties-window.c,v
retrieving revision 1.217
diff -u -p -r1.217 fm-properties-window.c
--- src/file-manager/fm-properties-window.c	11 Jul 2005 10:07:53 -0000	1.217
+++ src/file-manager/fm-properties-window.c	10 Aug 2005 07:49:23 -0000
@@ -538,7 +538,8 @@ fm_properties_window_drag_data_received 
 }
 
 static GtkWidget *
-create_image_widget (FMPropertiesWindow *window)
+create_image_widget (FMPropertiesWindow *window,
+		     gboolean is_drag_dest)
 {
  	GtkWidget *image;
 	GdkPixbuf *pixbuf;
@@ -548,14 +549,16 @@ create_image_widget (FMPropertiesWindow 
 	image = gtk_image_new ();
 	window->details->icon_image = image;
 
-	/* prepare the image to receive dropped objects to assign custom images */
-	gtk_drag_dest_set (GTK_WIDGET (image),
-			   GTK_DEST_DEFAULT_MOTION | GTK_DEST_DEFAULT_HIGHLIGHT | GTK_DEST_DEFAULT_DROP, 
-			   target_table, G_N_ELEMENTS (target_table),
-			   GDK_ACTION_COPY | GDK_ACTION_MOVE);
+	if (is_drag_dest) {
+		/* prepare the image to receive dropped objects to assign custom images */
+		gtk_drag_dest_set (GTK_WIDGET (image),
+				   GTK_DEST_DEFAULT_MOTION | GTK_DEST_DEFAULT_HIGHLIGHT | GTK_DEST_DEFAULT_DROP, 
+				   target_table, G_N_ELEMENTS (target_table),
+				   GDK_ACTION_COPY | GDK_ACTION_MOVE);
 
-	g_signal_connect (image, "drag_data_received",
-			  G_CALLBACK (fm_properties_window_drag_data_received), NULL);
+		g_signal_connect (image, "drag_data_received",
+				  G_CALLBACK (fm_properties_window_drag_data_received), NULL);
+	}
 
 	gtk_image_set_from_pixbuf (GTK_IMAGE (image), pixbuf);
 
@@ -2340,7 +2343,8 @@ create_basic_page (FMPropertiesWindow *w
 			  0, 0,
 			  0, 0);
 
-	icon_pixmap_widget = create_image_widget (window);
+	icon_pixmap_widget = create_image_widget (
+		window, should_show_custom_icon_buttons (window));
 	gtk_widget_show (icon_pixmap_widget);
 	
 	icon_aligner = gtk_alignment_new (1, 0.5, 0, 0);

Attachment: signature.asc
Description: This is a digitally signed message part

-- 
nautilus-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/nautilus-list

Reply via email to