Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/nautilus/ChangeLog,v
retrieving revision 1.6307
diff -u -p -r1.6307 ChangeLog
--- ChangeLog	18 Oct 2004 21:36:11 -0000	1.6307
+++ ChangeLog	20 Oct 2004 05:02:34 -0000
@@ -1,3 +1,9 @@
+2004-10-19  Dennis Cranston <dennis_cranston@yahoo.com>
+
+	* libnautilus-private/nautilus-desktop-link-monitor.c:
+	(nautilus_desktop_link_monitor_delete_link): Use appropriate
+	error dialogs for eject or unmount.
+	
 2004-10-18  Dave Camp  <dave@novell.com>
 
 	* src/file-manager/fm-directory-view.c:
Index: libnautilus-private/nautilus-desktop-link-monitor.c
===================================================================
RCS file: /cvs/gnome/nautilus/libnautilus-private/nautilus-desktop-link-monitor.c,v
retrieving revision 1.10
diff -u -p -r1.10 nautilus-desktop-link-monitor.c
--- libnautilus-private/nautilus-desktop-link-monitor.c	14 May 2004 09:34:07 -0000	1.10
+++ libnautilus-private/nautilus-desktop-link-monitor.c	20 Oct 2004 05:02:35 -0000
@@ -86,6 +86,52 @@ nautilus_desktop_link_monitor_get (void)
 	return link_monitor;
 }
 
+static void
+volume_delete_dialog (GtkWidget *parent_view,
+                      NautilusDesktopLink *link)
+{
+	GnomeVFSVolume *volume;
+	char *dialog_str;
+
+	volume = nautilus_desktop_link_get_volume (link);
+
+	if (volume != NULL) {
+
+		dialog_str = g_strdup_printf (
+	                 _("You cannot move the volume \"%s\" to the trash."),
+	                 nautilus_desktop_link_get_display_name (link));
+			 
+		switch (gnome_vfs_volume_get_device_type (volume)) {
+		case GNOME_VFS_DEVICE_TYPE_CDROM:
+		case GNOME_VFS_DEVICE_TYPE_ZIP:
+		case GNOME_VFS_DEVICE_TYPE_JAZ:
+		
+			eel_run_simple_dialog
+				(parent_view, 
+				 FALSE,
+				 GTK_MESSAGE_ERROR,
+				 dialog_str,
+				 _("If you want to eject the volume, please use Eject in the "
+				   "right-click menu of the volume."),
+				 NULL, GTK_STOCK_OK, NULL);
+			break;
+			
+		default:
+
+			eel_run_simple_dialog
+				(parent_view, 
+				 FALSE,
+				 GTK_MESSAGE_ERROR,
+				 dialog_str,
+				 _("If you want to unmount the volume, please use Unmount Volume in the "
+				   "right-click menu of the volume."),
+				 NULL, GTK_STOCK_OK, NULL);
+		}
+		
+		g_free (dialog_str);
+	}
+}
+
 void
 nautilus_desktop_link_monitor_delete_link (NautilusDesktopLinkMonitor *monitor,
 					   NautilusDesktopLink *link,
@@ -98,15 +144,7 @@ nautilus_desktop_link_monitor_delete_lin
 		/* just ignore. We don't allow you to delete these */
 		break;
 	default:
-		eel_run_simple_dialog
-			(parent_view, 
-			 FALSE,
-			 GTK_MESSAGE_ERROR,
-			 _("You cannot delete a volume icon."),
-			 _("If you want to eject the volume, please use Eject in the "
-			   "right-click menu of the volume."),
-			 _("Can't Delete Volume"),
-			 GTK_STOCK_OK, NULL);
+		volume_delete_dialog (parent_view, link);
 		break;
 	}
 }
