summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Larsson <alexl@redhat.com>2003-12-11 10:38:17 +0000
committerAlexander Larsson <alexl@src.gnome.org>2003-12-11 10:38:17 +0000
commit0b04cb7f9009429fe6a02020375dfab626b2ae6f (patch)
treeadc0fbe3144acd6d3d663bca26da2b86b36b929e
parent2088def1a33b679225b50afefe9abe49286458a1 (diff)
downloadnautilus-0b04cb7f9009429fe6a02020375dfab626b2ae6f.tar.gz
Update error dialogs to be HIGy, and use the new eel message dialog api.
2003-12-11 Alexander Larsson <alexl@redhat.com> * components/emblem/nautilus-emblem-view.c: * components/music/nautilus-music-view.c: * components/news/nautilus-news.c: * libnautilus-private/nautilus-desktop-link-monitor.c: * libnautilus-private/nautilus-emblem-utils.c: * libnautilus-private/nautilus-file-operations.c: * libnautilus-private/nautilus-icon-dnd.c: * libnautilus-private/nautilus-program-chooser.c: * libnautilus-private/nautilus-program-choosing.c: * src/file-manager/fm-directory-view.c: * src/file-manager/fm-error-reporting.c: * src/file-manager/fm-icon-view.c: * src/file-manager/fm-properties-window.c: * src/file-manager/fm-search-list-view.c: * src/file-manager/nautilus-indexing-info.c: * src/nautilus-application.c: * src/nautilus-connect-server-dialog.c: * src/nautilus-information-panel.c: * src/nautilus-location-bar.c: * src/nautilus-navigation-window-menus.c: * src/nautilus-navigation-window.c: * src/nautilus-property-browser.c: * src/nautilus-window-manage-views.c: * src/nautilus-window.c: Update error dialogs to be HIGy, and use the new eel message dialog api. Based on patch from dennis_cranston@yahoo.com
-rw-r--r--ChangeLog30
-rw-r--r--components/emblem/nautilus-emblem-view.c20
-rw-r--r--components/music/nautilus-music-view.c14
-rw-r--r--components/news/nautilus-news.c9
-rw-r--r--libnautilus-private/nautilus-desktop-link-monitor.c9
-rw-r--r--libnautilus-private/nautilus-emblem-utils.c25
-rw-r--r--libnautilus-private/nautilus-file-operations.c290
-rw-r--r--libnautilus-private/nautilus-icon-dnd.c20
-rw-r--r--libnautilus-private/nautilus-program-chooser.c59
-rw-r--r--libnautilus-private/nautilus-program-choosing.c69
-rw-r--r--src/file-manager/fm-directory-view.c90
-rw-r--r--src/file-manager/fm-error-reporting.c13
-rw-r--r--src/file-manager/fm-icon-view.c10
-rw-r--r--src/file-manager/fm-properties-window.c24
-rw-r--r--src/file-manager/fm-search-list-view.c99
-rw-r--r--src/file-manager/nautilus-indexing-info.c30
-rw-r--r--src/nautilus-application.c35
-rw-r--r--src/nautilus-connect-server-dialog.c9
-rw-r--r--src/nautilus-information-panel.c19
-rw-r--r--src/nautilus-location-bar.c15
-rw-r--r--src/nautilus-navigation-window-menus.c26
-rw-r--r--src/nautilus-navigation-window.c12
-rw-r--r--src/nautilus-property-browser.c31
-rw-r--r--src/nautilus-window-manage-views.c71
-rw-r--r--src/nautilus-window.c7
25 files changed, 576 insertions, 460 deletions
diff --git a/ChangeLog b/ChangeLog
index 798884699..e8ebcefb1 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,33 @@
+2003-12-11 Alexander Larsson <alexl@redhat.com>
+
+ * components/emblem/nautilus-emblem-view.c:
+ * components/music/nautilus-music-view.c:
+ * components/news/nautilus-news.c:
+ * libnautilus-private/nautilus-desktop-link-monitor.c:
+ * libnautilus-private/nautilus-emblem-utils.c:
+ * libnautilus-private/nautilus-file-operations.c:
+ * libnautilus-private/nautilus-icon-dnd.c:
+ * libnautilus-private/nautilus-program-chooser.c:
+ * libnautilus-private/nautilus-program-choosing.c:
+ * src/file-manager/fm-directory-view.c:
+ * src/file-manager/fm-error-reporting.c:
+ * src/file-manager/fm-icon-view.c:
+ * src/file-manager/fm-properties-window.c:
+ * src/file-manager/fm-search-list-view.c:
+ * src/file-manager/nautilus-indexing-info.c:
+ * src/nautilus-application.c:
+ * src/nautilus-connect-server-dialog.c:
+ * src/nautilus-information-panel.c:
+ * src/nautilus-location-bar.c:
+ * src/nautilus-navigation-window-menus.c:
+ * src/nautilus-navigation-window.c:
+ * src/nautilus-property-browser.c:
+ * src/nautilus-window-manage-views.c:
+ * src/nautilus-window.c:
+ Update error dialogs to be HIGy, and use the new
+ eel message dialog api.
+ Based on patch from dennis_cranston@yahoo.com
+
2003-12-10 Federico Mena Quintero <federico@ximian.com>
* src/nautilus-connect-server-dialog.c (response_callback): Use
diff --git a/components/emblem/nautilus-emblem-view.c b/components/emblem/nautilus-emblem-view.c
index a19219214..e572677a7 100644
--- a/components/emblem/nautilus-emblem-view.c
+++ b/components/emblem/nautilus-emblem-view.c
@@ -200,8 +200,9 @@ nautilus_emblem_view_delete_cb (GtkWidget *menu_item,
if (nautilus_emblem_remove_emblem (emblem_view->details->popup_emblem_keyword)) {
nautilus_emblem_view_refresh (emblem_view);
} else {
- error = g_strdup_printf (_("Couldn't remove emblem with name '%s'. This is probably because the emblem is a permanent one, and not one you added yourself."), emblem_view->details->popup_emblem_display_name);
- eel_show_error_dialog (error, _("Couldn't remove emblem"),
+ error = g_strdup_printf (_("Couldn't remove emblem with name '%s'."), emblem_view->details->popup_emblem_display_name);
+ eel_show_error_dialog (error, _("This is probably because the emblem is a permanent one, and not one you added yourself."),
+ _("Couldn't Remove Emblem"),
NULL);
g_free (error);
}
@@ -235,8 +236,9 @@ rename_dialog_response_cb (GtkWidget *dialog, int response,
if (nautilus_emblem_rename_emblem (keyword, name)) {
nautilus_emblem_view_refresh (emblem_view);
} else {
- error = g_strdup_printf (_("Couldn't rename emblem with name '%s'. This is probably because the emblem is a permanent one, and not one that you added yourself."), name);
- eel_show_error_dialog (error, _("Couldn't rename emblem"),
+ error = g_strdup_printf (_("Couldn't rename emblem with name '%s'."), name);
+ eel_show_error_dialog (error, _("This is probably because the emblem is a permanent one, and not one that you added yourself."),
+ _("Couldn't Rename Emblem"),
NULL);
g_free (error);
}
@@ -737,9 +739,9 @@ nautilus_emblem_view_drag_received_cb (GtkWidget *widget,
nautilus_icon_dnd_uri_list_free_strings (uris);
if (had_failure && emblems != NULL) {
- eel_show_error_dialog (_("Some of the files could not be added as emblems because they did not appear to be valid images."), _("Couldn't add emblems"), NULL);
+ eel_show_error_dialog (_("Some of the files could not be added as emblems."), _("The emblems do not appear to be valid images."), _("Couldn't Add Emblems"), NULL);
} else if (had_failure && emblems == NULL) {
- eel_show_error_dialog (_("None of the files could be added as emblems because they did not appear to be valid images."), _("Couldn't add emblems"), NULL);
+ eel_show_error_dialog (_("None of the files could be added as emblems."), _("The emblems do not appear to be valid images."), _("Couldn't Add Emblems"), NULL);
}
@@ -760,7 +762,7 @@ nautilus_emblem_view_drag_received_cb (GtkWidget *widget,
uri = g_strndup (data->data, data->length);
if (!eel_is_valid_uri (uri)) {
- eel_show_error_dialog (_("The dragged text was not a valid file location."), _("Couldn't add emblem"), NULL);
+ eel_show_error_dialog (_("The emblem cannot be added."), _("The dragged text was not a valid file location."), _("Couldn't Add Emblem"), NULL);
break;
}
@@ -785,7 +787,7 @@ nautilus_emblem_view_drag_received_cb (GtkWidget *widget,
} else {
error = g_strdup (_("The dragged file does not appear to be a valid image."));
}
- eel_show_error_dialog (error, _("Couldn't add emblem"),
+ eel_show_error_dialog (_("The emblem cannot be added."), error, _("Couldn't Add Emblem"),
NULL);
g_free (error);
g_free (uri_utf8);
@@ -835,7 +837,7 @@ nautilus_emblem_view_drag_received_cb (GtkWidget *widget,
g_warning ("Tried to load '%s', but failed.\n",
uri);
error = g_strdup_printf (_("The file '%s' does not appear to be a valid image."), uri);
- eel_show_error_dialog (error, _("Couldn't add emblem"),
+ eel_show_error_dialog (_("The emblem cannot be added."), error, _("Couldn't Add Emblem"),
NULL);
g_free (error);
}
diff --git a/components/music/nautilus-music-view.c b/components/music/nautilus-music-view.c
index c5e691443..d74eb4d97 100644
--- a/components/music/nautilus-music-view.c
+++ b/components/music/nautilus-music-view.c
@@ -742,7 +742,8 @@ set_album_cover (GtkWidget *widget, gpointer *data)
char *message = g_strdup_printf
(_("Sorry, but '%s' is not a usable image file."),
path_name);
- eel_show_error_dialog (message, _("Not an Image"), NULL);
+ eel_show_error_dialog (message, _("Please select an image file and try again."),
+ _("Not an Image"), NULL);
g_free (message);
g_free (path_uri);
@@ -1213,8 +1214,8 @@ play_current_file (NautilusMusicView *music_view, gboolean from_start)
g_object_unref (client);
if (!enable_esd) {
- eel_show_error_dialog (_("Sorry, but the music view is unable to play back sound right now. "
- "This is because the Enable sound server startup setting "
+ eel_show_error_dialog (_("Sorry, but the music view is unable to play back sound right now."),
+ _("This is because the Enable sound server startup setting "
"in the Sound section of the Control Center is turned off."),
_("Unable to Play File"),
//GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (&music_view->details->event_box->parent))));
@@ -1224,8 +1225,8 @@ play_current_file (NautilusMusicView *music_view, gboolean from_start)
}
if (!esdout_can_play ()) {
- eel_show_error_dialog (_("Sorry, but the music view is unable to play back sound right now. "
- "Either another program is using or blocking the sound card, "
+ eel_show_error_dialog (_("Sorry, but the music view is unable to play back sound right now."),
+ _("Either another program is using or blocking the sound card, "
"or your sound card is not configured properly. Try quitting any "
"applications that may be blocking use of the sound card."),
_("Unable to Play File"),
@@ -1253,6 +1254,7 @@ play_current_file (NautilusMusicView *music_view, gboolean from_start)
if (song_filename == NULL) {
eel_show_error_dialog
( _("Sorry, but the music view can't play non-local files yet."),
+ _("Remote files are not supported."),
_("Can't Play Remote Files"),
NULL);
return;
@@ -1765,7 +1767,7 @@ nautilus_music_view_update (NautilusMusicView *music_view)
if (result != GNOME_VFS_OK) {
path = gnome_vfs_get_local_path_from_uri (uri);
message = g_strdup_printf (_("Sorry, but there was an error reading %s."), path);
- eel_show_error_dialog (message, _("Can't Read Folder"),
+ eel_show_error_dialog (message, _("The folder cannot be read."), _("Can't Read Folder"),
GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (music_view->details->event_box))));
g_free (path);
g_free (message);
diff --git a/components/news/nautilus-news.c b/components/news/nautilus-news.c
index 6fbb5c754..93710e608 100644
--- a/components/news/nautilus-news.c
+++ b/components/news/nautilus-news.c
@@ -1755,11 +1755,13 @@ add_site_from_fields (GtkWidget *widget, News *news)
/* make sure there's something in the fields */
if (site_name == NULL || strlen (site_name) == 0) {
- eel_show_error_dialog (_("Sorry, but you have not specified a name for the site!"), _("Missing Site Name Error"), NULL);
+ eel_show_error_dialog (_("Sorry, but you have not specified a name for the site."),
+ _("Please specify a name and try again."), _("Missing Site Name Error"), NULL);
return;
}
if (site_location == NULL || strlen (site_location) == 0) {
- eel_show_error_dialog (_("Sorry, but you have not specified a URL for the site!"), _("Missing URL Error"), NULL);
+ eel_show_error_dialog (_("Sorry, but you have not specified a URL for the site."),
+ _("Please specify a URL and try again."), _("Missing URL Error"), NULL);
return;
}
@@ -1776,7 +1778,8 @@ add_site_from_fields (GtkWidget *widget, News *news)
g_free (buffer);
if (!got_xml_file) {
g_free (site_uri);
- eel_show_error_dialog (_("Sorry, but the specified url doesn't seem to be a valid RSS file!"), _("Invalid RSS URL"), NULL);
+ eel_show_error_dialog (_("Sorry, but the specified url doesn't seem to be a valid RSS file."),
+ _("Please check the spelling of the url."), _("Invalid RSS URL"), NULL);
return;
}
diff --git a/libnautilus-private/nautilus-desktop-link-monitor.c b/libnautilus-private/nautilus-desktop-link-monitor.c
index 47532f3ff..841784d6a 100644
--- a/libnautilus-private/nautilus-desktop-link-monitor.c
+++ b/libnautilus-private/nautilus-desktop-link-monitor.c
@@ -107,10 +107,11 @@ nautilus_desktop_link_monitor_delete_link (NautilusDesktopLinkMonitor *monitor,
eel_run_simple_dialog
(parent_view,
FALSE,
- _("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_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);
break;
}
diff --git a/libnautilus-private/nautilus-emblem-utils.c b/libnautilus-private/nautilus-emblem-utils.c
index 2aafeafaa..712ce735f 100644
--- a/libnautilus-private/nautilus-emblem-utils.c
+++ b/libnautilus-private/nautilus-emblem-utils.c
@@ -194,12 +194,14 @@ nautilus_emblem_verify_keyword (GtkWindow *parent_window,
const char *display_name)
{
if (keyword == NULL || strlen (keyword) == 0) {
- eel_show_error_dialog (_("Sorry, but you must specify a non-blank keyword for the new emblem."),
- _("Couldn't install emblem"), GTK_WINDOW (parent_window));
+ eel_show_error_dialog (_("The emblem cannot be installed."),
+ _("Sorry, but you must specify a non-blank keyword for the new emblem."),
+ _("Couldn't Install Emblem"), GTK_WINDOW (parent_window));
return FALSE;
} else if (!emblem_keyword_valid (keyword)) {
- eel_show_error_dialog (_("Sorry, but emblem keywords can only contain letters, spaces and numbers."),
- _("Couldn't install emblem"), GTK_WINDOW (parent_window));
+ eel_show_error_dialog (_("The emblem cannot be installed."),
+ _("Sorry, but emblem keywords can only contain letters, spaces and numbers."),
+ _("Couldn't Install Emblem"), GTK_WINDOW (parent_window));
return FALSE;
} else if (is_reserved_keyword (keyword)) {
char *error_string;
@@ -208,8 +210,8 @@ nautilus_emblem_verify_keyword (GtkWindow *parent_window,
* what a keyword is, and people should be passing a unique
* keyword to us anyway
*/
- error_string = g_strdup_printf (_("Sorry, but there is already an emblem named \"%s\". Please choose a different name for it."), display_name);
- eel_show_error_dialog (error_string,
+ error_string = g_strdup_printf (_("Sorry, but there is already an emblem named \"%s\"."), display_name);
+ eel_show_error_dialog (_("Please choose a different emblem name."), error_string,
_("Couldn't install emblem"), GTK_WINDOW (parent_window));
g_free (error_string);
return FALSE;
@@ -252,8 +254,10 @@ nautilus_emblem_install_custom_emblem (GdkPixbuf *pixbuf,
/* save the image */
if (eel_gdk_pixbuf_save_to_file (pixbuf, path) != TRUE) {
- eel_show_error_dialog (_("Sorry, unable to save custom emblem."),
- _("Couldn't install emblem"), GTK_WINDOW (parent_window));
+ eel_show_error_dialog (_("The emblem cannot be installed."),
+ _("Sorry, unable to save custom emblem."),
+ _("Couldn't Install Emblem"),
+ GTK_WINDOW (parent_window));
g_free (dir);
g_free (stat_dir);
g_free (path);
@@ -267,8 +271,9 @@ nautilus_emblem_install_custom_emblem (GdkPixbuf *pixbuf,
file = fopen (path, "w+");
if (file == NULL) {
- eel_show_error_dialog (_("Sorry, unable to save custom emblem name."),
- _("Couldn't install emblem"), GTK_WINDOW (parent_window));
+ eel_show_error_dialog (_("The emblem cannot be installed."),
+ _("Sorry, unable to save custom emblem name."),
+ _("Couldn't Install Emblem"), GTK_WINDOW (parent_window));
g_free (stat_dir);
g_free (dir);
return;
diff --git a/libnautilus-private/nautilus-file-operations.c b/libnautilus-private/nautilus-file-operations.c
index 3f9586caf..fe64cef28 100644
--- a/libnautilus-private/nautilus-file-operations.c
+++ b/libnautilus-private/nautilus-file-operations.c
@@ -516,12 +516,13 @@ typedef enum {
} NautilusFileOperationsErrorLocation;
-static char *
+static void
build_error_string (const char *source_name, const char *target_name,
TransferKind operation_kind,
NautilusFileOperationsErrorKind error_kind,
NautilusFileOperationsErrorLocation error_location,
- GnomeVFSResult error)
+ GnomeVFSResult error,
+ char **error_string, char **detail_string)
{
/* Avoid clever message composing here, just use brute force and
* duplicate the different flavors of error messages for all the
@@ -530,11 +531,14 @@ build_error_string (const char *source_name, const char *target_name,
* order of the words in the messages easily.
*/
- const char *error_string;
- char *result;
+ char *error_format;
+ char *detail_format;
+
+ error_format = NULL;
+ detail_format = NULL;
- error_string = NULL;
- result = NULL;
+ *error_string = NULL;
+ *detail_string = NULL;
if (error_location == ERROR_LOCATION_SOURCE_PARENT) {
@@ -542,9 +546,9 @@ build_error_string (const char *source_name, const char *target_name,
case TRANSFER_MOVE:
case TRANSFER_MOVE_TO_TRASH:
if (error_kind == ERROR_READ_ONLY) {
- error_string = _("Error while moving.\n\n"
- "\"%s\" cannot be moved because it is on "
- "a read-only disk.");
+ *error_string = g_strdup (_("Error while moving."));
+ detail_format = _("\"%s\" cannot be moved because it is on "
+ "a read-only disk.");
}
break;
@@ -553,15 +557,15 @@ build_error_string (const char *source_name, const char *target_name,
switch (error_kind) {
case ERROR_NOT_ENOUGH_PERMISSIONS:
case ERROR_NOT_WRITABLE:
- error_string = _("Error while deleting.\n\n"
- "\"%s\" cannot be deleted because you do not have "
- "permissions to modify its parent folder.");
+ *error_string = g_strdup (_("Error while deleting."));
+ detail_format = _("\"%s\" cannot be deleted because you do not have "
+ "permissions to modify its parent folder.");
break;
case ERROR_READ_ONLY:
- error_string = _("Error while deleting.\n\n"
- "\"%s\" cannot be deleted because it is on "
- "a read-only disk.");
+ *error_string = g_strdup (_("Error while deleting."));
+ detail_format = _("\"%s\" cannot be deleted because it is on "
+ "a read-only disk.");
break;
default:
@@ -574,8 +578,8 @@ build_error_string (const char *source_name, const char *target_name,
break;
}
- if (error_string != NULL && source_name != NULL) {
- result = g_strdup_printf (error_string, source_name);
+ if (detail_format != NULL && source_name != NULL) {
+ *detail_string = g_strdup_printf (detail_format, source_name);
}
} else if (error_location == ERROR_LOCATION_SOURCE_OR_PARENT) {
@@ -590,14 +594,14 @@ build_error_string (const char *source_name, const char *target_name,
case TRANSFER_MOVE:
switch (error_kind) {
case ERROR_NOT_ENOUGH_PERMISSIONS:
- error_string = _("Error while moving.\n\n"
- "\"%s\" cannot be moved because you do not have "
- "permissions to change it or its parent folder.");
+ *error_string = g_strdup (_("Error while moving."));
+ detail_format = _("\"%s\" cannot be moved because you do not have "
+ "permissions to change it or its parent folder.");
break;
case ERROR_SOURCE_IN_TARGET:
- error_string = _("Error while moving.\n\n"
- "\"%s\" cannot be moved because it or its parent folder "
- "are contained in the destination.");
+ *error_string = g_strdup (_("Error while moving. "));
+ detail_format = _("Cannot move \"%s\" because it or its parent folder "
+ "are contained in the destination.");
break;
default:
break;
@@ -605,9 +609,9 @@ build_error_string (const char *source_name, const char *target_name,
break;
case TRANSFER_MOVE_TO_TRASH:
if (error_kind == ERROR_NOT_ENOUGH_PERMISSIONS) {
- error_string = _("Error while moving.\n\n"
- "\"%s\" cannot be moved to the Trash because you do not have "
- "permissions to change it or its parent folder.");
+ *error_string = g_strdup (_("Error while moving."));
+ detail_format = _("Cannot move \"%s\" to the trash because you do not have "
+ "permissions to change it or its parent folder.");
}
break;
@@ -616,8 +620,8 @@ build_error_string (const char *source_name, const char *target_name,
break;
}
- if (error_string != NULL && source_name != NULL) {
- result = g_strdup_printf (error_string, source_name);
+ if (detail_format != NULL && source_name != NULL) {
+ *detail_string = g_strdup_printf (detail_format, source_name);
}
} else if (error_location == ERROR_LOCATION_SOURCE) {
@@ -628,9 +632,9 @@ build_error_string (const char *source_name, const char *target_name,
case TRANSFER_COPY:
case TRANSFER_DUPLICATE:
if (error_kind == ERROR_NOT_READABLE) {
- error_string = _("Error while copying.\n\n"
- "\"%s\" cannot be copied because you do not have "
- "permissions to read it.");
+ *error_string = g_strdup (_("Error while copying."));
+ detail_format = _("\"%s\" cannot be copied because you do not have "
+ "permissions to read it.");
}
break;
@@ -639,8 +643,8 @@ build_error_string (const char *source_name, const char *target_name,
break;
}
- if (error_string != NULL && source_name != NULL) {
- result = g_strdup_printf (error_string, source_name);
+ if (detail_format != NULL && source_name != NULL) {
+ *detail_string = g_strdup_printf (detail_format, source_name);
}
} else if (error_location == ERROR_LOCATION_TARGET) {
@@ -649,17 +653,17 @@ build_error_string (const char *source_name, const char *target_name,
switch (operation_kind) {
case TRANSFER_COPY:
case TRANSFER_DUPLICATE:
- error_string = _("Error while copying to \"%s\".\n\n"
- "There is not enough space on the destination.");
+ error_format = _("Error while copying to \"%s\".");
+ *detail_string = g_strdup (_("There is not enough space on the destination."));
break;
case TRANSFER_MOVE_TO_TRASH:
case TRANSFER_MOVE:
- error_string = _("Error while moving to \"%s\".\n\n"
- "There is not enough space on the destination.");
+ error_format = _("Error while moving to \"%s\".");
+ *detail_string = g_strdup (_("There is not enough space on the destination."));
break;
case TRANSFER_LINK:
- error_string = _("Error while creating link in \"%s\".\n\n"
- "There is not enough space on the destination.");
+ error_format = _("Error while creating link in \"%s\".");
+ *detail_string = g_strdup (_("There is not enough space on the destination."));
break;
default:
g_assert_not_reached ();
@@ -670,34 +674,34 @@ build_error_string (const char *source_name, const char *target_name,
case TRANSFER_COPY:
case TRANSFER_DUPLICATE:
if (error_kind == ERROR_NOT_ENOUGH_PERMISSIONS) {
- error_string = _("Error while copying to \"%s\".\n\n"
- "You do not have permissions to write to "
- "this folder.");
+ error_format = _("Error while copying to \"%s\".");
+ *detail_string = g_strdup (_("You do not have permissions to write to "
+ "this folder."));
} else if (error_kind == ERROR_NOT_WRITABLE) {
- error_string = _("Error while copying to \"%s\".\n\n"
- "The destination disk is read-only.");
+ error_format = _("Error while copying to \"%s\".");
+ *detail_string = g_strdup (_("The destination disk is read-only."));
}
break;
case TRANSFER_MOVE:
case TRANSFER_MOVE_TO_TRASH:
if (error_kind == ERROR_NOT_ENOUGH_PERMISSIONS) {
- error_string = _("Error while moving items to \"%s\".\n\n"
- "You do not have permissions to write to "
- "this folder.");
+ error_format = _("Error while moving items to \"%s\".");
+ *detail_string = g_strdup (_("You do not have permissions to write to "
+ "this folder."));
} else if (error_kind == ERROR_NOT_WRITABLE) {
- error_string = _("Error while moving items to \"%s\".\n\n"
- "The destination disk is read-only.");
+ error_format = _("Error while moving items to \"%s\".");
+ *detail_string = g_strdup (_("The destination disk is read-only."));
}
break;
case TRANSFER_LINK:
if (error_kind == ERROR_NOT_ENOUGH_PERMISSIONS) {
- error_string = _("Error while creating links in \"%s\".\n\n"
- "You do not have permissions to write to "
- "this folder.");
+ error_format = _("Error while creating links in \"%s\".");
+ *detail_string = g_strdup (_("You do not have permissions to write to "
+ "this folder."));
} else if (error_kind == ERROR_NOT_WRITABLE) {
- error_string = _("Error while creating links in \"%s\".\n\n"
- "The destination disk is read-only.");
+ error_format = _("Error while creating links in \"%s\".");
+ *detail_string = g_strdup (_("The destination disk is read-only."));
}
break;
default:
@@ -705,12 +709,12 @@ build_error_string (const char *source_name, const char *target_name,
break;
}
}
- if (error_string != NULL && target_name != NULL) {
- result = g_strdup_printf (error_string, target_name);
+ if (error_format != NULL && target_name != NULL) {
+ *error_string = g_strdup_printf (error_format, target_name);
}
}
- if (result == NULL) {
+ if (*error_string == NULL) {
/* None of the specific error messages apply, use a catch-all
* generic error
*/
@@ -724,62 +728,61 @@ build_error_string (const char *source_name, const char *target_name,
switch (operation_kind) {
case TRANSFER_COPY:
case TRANSFER_DUPLICATE:
- error_string = _("Error \"%s\" while copying \"%s\".\n\n"
- "Would you like to continue?");
+ error_format = _("Error \"%s\" while copying \"%s\".");
+ *detail_string = g_strdup (_("Would you like to continue?"));
break;
case TRANSFER_MOVE:
- error_string = _("Error \"%s\" while moving \"%s\".\n\n"
- "Would you like to continue?");
+ error_format = _("Error \"%s\" while moving \"%s\".");
+ *detail_string = g_strdup (_("Would you like to continue?"));
break;
case TRANSFER_LINK:
- error_string = _("Error \"%s\" while creating a link to \"%s\".\n\n"
- "Would you like to continue?");
+ error_format = _("Error \"%s\" while creating a link to \"%s\".");
+ *detail_string = g_strdup (_("Would you like to continue?"));
break;
case TRANSFER_DELETE:
case TRANSFER_EMPTY_TRASH:
case TRANSFER_MOVE_TO_TRASH:
- error_string = _("Error \"%s\" while deleting \"%s\".\n\n"
- "Would you like to continue?");
+ error_format = _("Error \"%s\" while deleting \"%s\".");
+ *detail_string = g_strdup (_("Would you like to continue?"));
break;
default:
g_assert_not_reached ();
break;
}
- result = g_strdup_printf (error_string,
- gnome_vfs_result_to_string (error),
- source_name);
+ *error_string = g_strdup_printf (error_format,
+ gnome_vfs_result_to_string (error),
+ source_name);
} else {
switch (operation_kind) {
case TRANSFER_COPY:
case TRANSFER_DUPLICATE:
- error_string = _("Error \"%s\" while copying.\n\n"
- "Would you like to continue?");
+ error_format = _("Error \"%s\" while copying.");
+ *detail_string = g_strdup (_("Would you like to continue?"));
break;
case TRANSFER_MOVE:
- error_string = _("Error \"%s\" while moving.\n\n"
- "Would you like to continue?");
+ error_format = _("Error \"%s\" while moving.");
+ *detail_string = g_strdup (_("Would you like to continue?"));
break;
case TRANSFER_LINK:
- error_string = _("Error \"%s\" while linking.\n\n"
- "Would you like to continue?");
+ error_format = _("Error \"%s\" while linking.");
+ *detail_string = g_strdup (_("Would you like to continue?"));
break;
case TRANSFER_DELETE:
case TRANSFER_EMPTY_TRASH:
case TRANSFER_MOVE_TO_TRASH:
- error_string = _("Error \"%s\" while deleting.\n\n"
- "Would you like to continue?");
+ error_format = _("Error \"%s\" while deleting.");
+ *detail_string = g_strdup (_("Would you like to continue?"));
break;
default:
g_assert_not_reached ();
break;
}
- result = g_strdup_printf (error_string,
- gnome_vfs_result_to_string (error));
+ *error_string = g_strdup_printf (error_format,
+ gnome_vfs_result_to_string (error));
}
}
- return result;
}
static int
@@ -794,6 +797,7 @@ handle_transfer_vfs_error (const GnomeVFSXferProgressInfo *progress_info,
int error_dialog_button_pressed;
int error_dialog_result;
char *text;
+ char *detail;
char *formatted_source_name;
char *formatted_target_name;
const char *dialog_title;
@@ -884,26 +888,27 @@ handle_transfer_vfs_error (const GnomeVFSXferProgressInfo *progress_info,
error_kind = ERROR_SOURCE_IN_TARGET;
}
- text = build_error_string (formatted_source_name, formatted_target_name,
- transfer_info->kind,
- error_kind, error_location,
- progress_info->vfs_status);
+ build_error_string (formatted_source_name, formatted_target_name,
+ transfer_info->kind,
+ error_kind, error_location,
+ progress_info->vfs_status,
+ &text, &detail);
switch (transfer_info->kind) {
case TRANSFER_COPY:
case TRANSFER_DUPLICATE:
- dialog_title = _("Error while copying.");
+ dialog_title = _("Error While Copying");
break;
case TRANSFER_MOVE:
- dialog_title = _("Error while moving.");
+ dialog_title = _("Error While Moving");
break;
case TRANSFER_LINK:
- dialog_title = _("Error while linking.");
+ dialog_title = _("Error While Linking");
break;
case TRANSFER_DELETE:
case TRANSFER_EMPTY_TRASH:
case TRANSFER_MOVE_TO_TRASH:
- dialog_title = _("Error while deleting.");
+ dialog_title = _("Error While Deleting");
break;
default:
dialog_title = NULL;
@@ -914,7 +919,7 @@ handle_transfer_vfs_error (const GnomeVFSXferProgressInfo *progress_info,
error_kind == ERROR_SOURCE_IN_TARGET) {
/* We can't continue, just tell the user. */
eel_run_simple_dialog (parent_for_error_dialog (transfer_info),
- TRUE, text, dialog_title, GTK_STOCK_OK, NULL);
+ TRUE, GTK_MESSAGE_ERROR, text, detail, dialog_title, GTK_STOCK_OK, NULL);
error_dialog_result = GNOME_VFS_XFER_ERROR_ACTION_ABORT;
} else if ((error_location == ERROR_LOCATION_SOURCE
@@ -927,9 +932,10 @@ handle_transfer_vfs_error (const GnomeVFSXferProgressInfo *progress_info,
* continue. Allow the user to skip.
*/
error_dialog_button_pressed = eel_run_simple_dialog
- (parent_for_error_dialog (transfer_info), TRUE, text,
- dialog_title,
- GTK_STOCK_CANCEL, _("Skip"), NULL);
+ (parent_for_error_dialog (transfer_info), TRUE,
+ GTK_MESSAGE_ERROR, text,
+ detail, dialog_title,
+ GTK_STOCK_CANCEL, _("_Skip"), NULL);
switch (error_dialog_button_pressed) {
case 0:
@@ -947,9 +953,10 @@ handle_transfer_vfs_error (const GnomeVFSXferProgressInfo *progress_info,
} else {
/* Generic error, offer to retry and skip. */
error_dialog_button_pressed = eel_run_simple_dialog
- (parent_for_error_dialog (transfer_info), TRUE, text,
- dialog_title,
- _("Skip"), GTK_STOCK_CANCEL, _("Retry"), NULL);
+ (parent_for_error_dialog (transfer_info), TRUE,
+ GTK_MESSAGE_ERROR, text,
+ detail, dialog_title,
+ _("_Skip"), GTK_STOCK_CANCEL, _("_Retry"), NULL);
switch (error_dialog_button_pressed) {
case 0:
@@ -968,6 +975,7 @@ handle_transfer_vfs_error (const GnomeVFSXferProgressInfo *progress_info,
}
g_free (text);
+ g_free (detail);
g_free (formatted_source_name);
g_free (formatted_target_name);
@@ -1003,7 +1011,7 @@ handle_transfer_overwrite (const GnomeVFSXferProgressInfo *progress_info,
TransferInfo *transfer_info)
{
int result;
- char *text, *formatted_name;
+ char *text, *primary_text, *secondary_text, *formatted_name;
nautilus_file_operations_progress_pause_timeout (transfer_info->progress_dialog);
@@ -1014,23 +1022,25 @@ handle_transfer_overwrite (const GnomeVFSXferProgressInfo *progress_info,
progress_info->target_name);
if (transfer_info->kind == TRANSFER_MOVE) {
- text = g_strdup_printf (_("\"%s\" could not be moved to the new location, "
- "because its name is already used for a special item that "
- "cannot be removed or replaced.\n\n"
- "If you still want to move \"%s\", rename it and try again."),
- formatted_name, formatted_name);
- } else {
- text = g_strdup_printf (_("\"%s\" could not be copied to the new location, "
- "because its name is already used for a special item that "
- "cannot be removed or replaced.\n\n"
- "If you still want to copy \"%s\", rename it and try again."),
- formatted_name, formatted_name);
+ primary_text = g_strdup_printf (_("Could not move \"%s\" to the new location."),
+ formatted_name);
+
+ secondary_text = _("The name is already used for a special item that "
+ "cannot be removed or replaced. If you still want "
+ "to move the item, rename it and try again.");
+ } else {
+ primary_text = g_strdup_printf (_("Could not copy \"%s\" to the new location."),
+ formatted_name);
+
+ secondary_text = _("The name is already used for a special item that "
+ "cannot be removed or replaced. If you still want "
+ "to copy the item, rename it and try again.");
}
- eel_run_simple_dialog (parent_for_error_dialog (transfer_info), TRUE, text,
- _("Unable to replace file."), GTK_STOCK_OK, NULL, NULL);
+ eel_run_simple_dialog (parent_for_error_dialog (transfer_info), TRUE, GTK_MESSAGE_ERROR, primary_text, secondary_text,
+ _("Unable to Replace File"), GTK_STOCK_OK, NULL, NULL);
- g_free (text);
+ g_free (primary_text);
g_free (formatted_name);
nautilus_file_operations_progress_resume_timeout (transfer_info->progress_dialog);
@@ -1041,37 +1051,41 @@ handle_transfer_overwrite (const GnomeVFSXferProgressInfo *progress_info,
/* transfer conflict, prompt the user to replace or skip */
formatted_name = format_and_ellipsize_uri_for_dialog (
parent_for_error_dialog (transfer_info), progress_info->target_name);
- text = g_strdup_printf (_("File \"%s\" already exists.\n\n"
- "Would you like to replace it?"),
- formatted_name);
+ text = g_strdup_printf (_("The file \"%s\" already exists. Would you like to replace it?"),
+ formatted_name);
g_free (formatted_name);
if (progress_info->duplicate_count == 1) {
/* we are going to only get one duplicate alert, don't offer
* Replace All
*/
- result = eel_run_simple_dialog
- (parent_for_error_dialog (transfer_info), TRUE, text,
- _("Conflict while copying"),
- _("Replace"), _("Skip"), NULL);
+ result = eel_run_simple_dialog
+ (parent_for_error_dialog (transfer_info),
+ TRUE,
+ GTK_MESSAGE_QUESTION,
+ text,
+ _("If you replace an existing file, its contents will be overwritten."),
+ _("Conflict While Copying"),
+ _("_Skip"), _("_Replace"), NULL);
g_free (text);
nautilus_file_operations_progress_resume_timeout (transfer_info->progress_dialog);
switch (result) {
case 0:
- return GNOME_VFS_XFER_OVERWRITE_ACTION_REPLACE;
+ return GNOME_VFS_XFER_OVERWRITE_ACTION_SKIP;
default:
g_assert_not_reached ();
/* fall through */
case 1:
- return GNOME_VFS_XFER_OVERWRITE_ACTION_SKIP;
+ return GNOME_VFS_XFER_OVERWRITE_ACTION_REPLACE;
}
} else {
result = eel_run_simple_dialog
- (parent_for_error_dialog (transfer_info), TRUE, text,
- _("Conflict while copying"),
- _("Replace All"), _("Replace"), _("Skip"), NULL);
+ (parent_for_error_dialog (transfer_info), TRUE, GTK_MESSAGE_QUESTION, text,
+ _("If you replace an existing file, its contents will be overwritten."),
+ _("Conflict While Copying"),
+ _("Replace _All"), _("_Skip"), _("_Replace"), NULL);
g_free (text);
nautilus_file_operations_progress_resume_timeout (transfer_info->progress_dialog);
@@ -1080,12 +1094,12 @@ handle_transfer_overwrite (const GnomeVFSXferProgressInfo *progress_info,
case 0:
return GNOME_VFS_XFER_OVERWRITE_ACTION_REPLACE_ALL;
case 1:
- return GNOME_VFS_XFER_OVERWRITE_ACTION_REPLACE;
+ return GNOME_VFS_XFER_OVERWRITE_ACTION_SKIP;
default:
g_assert_not_reached ();
/* fall through */
case 2:
- return GNOME_VFS_XFER_OVERWRITE_ACTION_SKIP;
+ return GNOME_VFS_XFER_OVERWRITE_ACTION_REPLACE;
}
}
}
@@ -1909,8 +1923,10 @@ nautilus_file_operations_copy_move (const GList *item_uris,
eel_run_simple_dialog
(parent_view,
FALSE,
- _("You cannot copy items into the Trash."),
- _("Can't Copy to Trash"),
+ GTK_MESSAGE_ERROR,
+ _("You cannot copy items into the trash."),
+ _("Files and folders can only be moved into the trash."),
+ NULL,
GTK_STOCK_OK, NULL);
result = GNOME_VFS_ERROR_NOT_PERMITTED;
}
@@ -1931,9 +1947,11 @@ nautilus_file_operations_copy_move (const GList *item_uris,
eel_run_simple_dialog
(parent_view,
FALSE,
+ GTK_MESSAGE_ERROR,
((move_options & GNOME_VFS_XFER_REMOVESOURCE) != 0)
? _("You cannot move this trash folder.")
: _("You cannot copy this trash folder."),
+ _("A trash folder is used for storing items moved to the trash."),
((move_options & GNOME_VFS_XFER_REMOVESOURCE) != 0)
? _("Can't Change Trash Location")
: _("Can't Copy Trash"),
@@ -1958,9 +1976,11 @@ nautilus_file_operations_copy_move (const GList *item_uris,
eel_run_simple_dialog
(parent_view,
FALSE,
+ GTK_MESSAGE_ERROR,
((move_options & GNOME_VFS_XFER_REMOVESOURCE) != 0)
? _("You cannot move a folder into itself.")
: _("You cannot copy a folder into itself."),
+ _("The destination folder is inside the source folder."),
((move_options & GNOME_VFS_XFER_REMOVESOURCE) != 0)
? _("Can't Move Into Self")
: _("Can't Copy Into Self"),
@@ -1975,7 +1995,9 @@ nautilus_file_operations_copy_move (const GList *item_uris,
eel_run_simple_dialog
(parent_view,
FALSE,
- _("You cannot copy a file over itself."),
+ GTK_MESSAGE_ERROR,
+ _("You cannot copy a file over itself."),
+ _("The destination and source are the same file."),
_("Can't Copy Over Self"),
GTK_STOCK_OK, NULL, NULL);
@@ -2028,17 +2050,16 @@ handle_new_folder_vfs_error (const GnomeVFSXferProgressInfo *progress_info, NewF
error_string_to_free = NULL;
if (progress_info->vfs_status == GNOME_VFS_ERROR_ACCESS_DENIED) {
- error_string = _("Error creating new folder.\n\n"
- "You do not have permissions to write to the destination.");
+ error_string = _("You do not have permissions to write to the destination.");
} else if (progress_info->vfs_status == GNOME_VFS_ERROR_NO_SPACE) {
- error_string = _("Error creating new folder.\n\n"
- "There is no space on the destination.");
+ error_string = _("There is no space on the destination.");
} else {
error_string = g_strdup_printf (_("Error \"%s\" creating new folder."),
- gnome_vfs_result_to_string(progress_info->vfs_status));
+ gnome_vfs_result_to_string (progress_info->vfs_status));
+ error_string_to_free = (char *)error_string;
}
- eel_show_error_dialog (error_string, _("Error creating new folder"),
+ eel_show_error_dialog (_("Error creating new folder."), error_string, _("Error Creating New Folder"),
GTK_WINDOW (gtk_widget_get_toplevel (state->parent_view)));
g_free (error_string_to_free);
@@ -2282,6 +2303,7 @@ confirm_empty_trash (GtkWidget *parent_view)
image = gtk_image_new_from_stock (GTK_STOCK_DIALOG_QUESTION,
GTK_ICON_SIZE_DIALOG);
+ gtk_misc_set_alignment (GTK_MISC (image), 0.5, 0.0);
gtk_widget_show (image);
gtk_box_pack_start (GTK_BOX (hbox), image, FALSE, FALSE, 0);
@@ -2289,10 +2311,10 @@ confirm_empty_trash (GtkWidget *parent_view)
gtk_box_pack_start (GTK_BOX (hbox), vbox, TRUE, TRUE, 0);
gtk_widget_show (vbox);
- str = g_strconcat ("<b>",
+ str = g_strconcat ("<span weight=\"bold\" size=\"larger\">",
_("Are you sure you want to empty "
"all of the items from the trash?"),
- "</b>",
+ "</span>",
NULL);
label = gtk_label_new (str);
diff --git a/libnautilus-private/nautilus-icon-dnd.c b/libnautilus-private/nautilus-icon-dnd.c
index 618f39653..0d4cffd81 100644
--- a/libnautilus-private/nautilus-icon-dnd.c
+++ b/libnautilus-private/nautilus-icon-dnd.c
@@ -718,6 +718,7 @@ confirm_switch_to_manual_layout (NautilusIconContainer *container)
{
#if 0
const char *message;
+ const char *detail;
GtkDialog *dialog;
int response;
@@ -728,25 +729,26 @@ confirm_switch_to_manual_layout (NautilusIconContainer *container)
*/
if (nautilus_icon_container_has_stored_icon_positions (container)) {
if (eel_g_list_exactly_one_item (container->details->dnd_info->drag_info.selection_list)) {
- message = _("This folder uses automatic layout. "
- "Do you want to switch to manual layout and leave this item where you dropped it? "
+ message = _("Do you want to switch to manual layout and leave this item where you dropped it? "
"This will clobber the stored manual layout.");
+ detail = _("This folder uses automatic layout.");
} else {
- message = _("This folder uses automatic layout. "
- "Do you want to switch to manual layout and leave these items where you dropped them? "
+ message = _("Do you want to switch to manual layout and leave these items where you dropped them? "
"This will clobber the stored manual layout.");
+ detail = _("This folder uses automatic layout.");
}
} else {
if (eel_g_list_exactly_one_item (container->details->dnd_info->drag_info.selection_list)) {
- message = _("This folder uses automatic layout. "
- "Do you want to switch to manual layout and leave this item where you dropped it?");
+ message = _("Do you want to switch to manual layout and leave this item where you dropped it?");
+ detail = _("This folder uses automatic layout.");
} else {
- message = _("This folder uses automatic layout. "
- "Do you want to switch to manual layout and leave these items where you dropped them?");
+ message = _("Do you want to switch to manual layout and leave these items where you dropped them?");
+ detail = _("This folder uses automatic layout.");
+
}
}
- dialog = eel_show_yes_no_dialog (message, _("Switch to Manual Layout?"),
+ dialog = eel_show_yes_no_dialog (message, detail, _("Switch to Manual Layout?"),
_("Switch"), GTK_STOCK_CANCEL,
GTK_WINDOW (gtk_widget_get_toplevel(GTK_WIDGET(container))));
diff --git a/libnautilus-private/nautilus-program-chooser.c b/libnautilus-private/nautilus-program-chooser.c
index 79dad5655..2fe274d6c 100644
--- a/libnautilus-private/nautilus-program-chooser.c
+++ b/libnautilus-private/nautilus-program-chooser.c
@@ -983,17 +983,6 @@ launch_mime_capplet (NautilusFile *file,
}
static void
-launch_mime_capplet_on_ok (GtkDialog *dialog, int response, gpointer callback_data)
-{
- g_assert (GTK_IS_DIALOG (dialog));
-
- if (response == GTK_RESPONSE_YES) {
- launch_mime_capplet (callback_data, dialog);
- }
- gtk_object_destroy (GTK_OBJECT (dialog));
-}
-
-static void
launch_mime_capplet_and_close_dialog (GtkButton *button, gpointer callback_data)
{
ProgramFilePair *file_pair;
@@ -1594,6 +1583,7 @@ nautilus_program_chooser_show_no_choices_message (GnomeVFSMimeActionType action_
char *file_name;
char *dialog_title;
GtkDialog *dialog;
+ int response;
file_name = get_file_name_for_display (file);
@@ -1612,22 +1602,22 @@ nautilus_program_chooser_show_no_choices_message (GnomeVFSMimeActionType action_
* user can't add components to the complete list even from the capplet.
* (They can add applications though.)
*/
- prompt = g_strdup_printf (_("%s\n\n"
- "You can configure GNOME to associate applications "
- "with file types. Do you want to associate an "
- "application with this file type now?"),
- unavailable_message);
-
- dialog = eel_show_yes_no_dialog
- (prompt, dialog_title, _("Associate Application"), GTK_STOCK_CANCEL, parent_window);
+ prompt = _("You can configure GNOME to associate applications "
+ "with file types. Do you want to associate an "
+ "application with this file type now?");
+
+ dialog = eel_show_yes_no_dialog (unavailable_message, prompt, dialog_title,
+ _("_Associate Application"), GTK_STOCK_CANCEL, parent_window);
+
+ response = gtk_dialog_run (dialog);
+ gtk_object_destroy (GTK_OBJECT (dialog));
- g_signal_connect_object (dialog, "response",
- G_CALLBACK (launch_mime_capplet_on_ok),
- file, 0);
+ if (response == GTK_RESPONSE_YES) {
+ launch_mime_capplet (file, dialog);
+ }
g_free (unavailable_message);
g_free (file_name);
- g_free (prompt);
g_free (dialog_title);
}
@@ -1641,6 +1631,7 @@ nautilus_program_chooser_show_invalid_message (GnomeVFSMimeActionType action_ty
char *file_name;
char *dialog_title;
GtkDialog *dialog;
+ int response;
file_name = get_file_name_for_display (file);
@@ -1655,21 +1646,21 @@ nautilus_program_chooser_show_invalid_message (GnomeVFSMimeActionType action_ty
dialog_title = g_strdup (_("Invalid Action Associated"));
}
- prompt = g_strdup_printf (_("%s\n\n"
- "You can configure GNOME to associate a different application "
- "or viewer with this file type. Do you want to associate an "
- "application or viewer with this file type now?"),
- unavailable_message);
+ prompt = _("You can configure GNOME to associate a different application "
+ "or viewer with this file type. Do you want to associate an "
+ "application or viewer with this file type now?");
- dialog = eel_show_yes_no_dialog
- (prompt, dialog_title, _("Associate Action"), GTK_STOCK_CANCEL, parent_window);
+ dialog = eel_show_yes_no_dialog (unavailable_message, prompt, dialog_title,
+ _("_Associate Action"), GTK_STOCK_CANCEL, parent_window);
- g_signal_connect_object (dialog, "response",
- G_CALLBACK (launch_mime_capplet_on_ok),
- file, 0);
+ response = gtk_dialog_run (dialog);
+ gtk_object_destroy (GTK_OBJECT (dialog));
+
+ if (response == GTK_RESPONSE_YES) {
+ launch_mime_capplet (file, dialog);
+ }
g_free (unavailable_message);
g_free (file_name);
- g_free (prompt);
g_free (dialog_title);
}
diff --git a/libnautilus-private/nautilus-program-choosing.c b/libnautilus-private/nautilus-program-choosing.c
index a0ac18cbc..900ce1806 100644
--- a/libnautilus-private/nautilus-program-choosing.c
+++ b/libnautilus-private/nautilus-program-choosing.c
@@ -493,6 +493,7 @@ application_cannot_open_location (GnomeVFSMimeApplication *application,
{
GtkDialog *message_dialog;
LaunchParameters *launch_parameters;
+ char *prompt;
char *message;
char *file_name;
int response;
@@ -501,17 +502,20 @@ application_cannot_open_location (GnomeVFSMimeApplication *application,
if (nautilus_mime_has_any_applications_for_file (file)) {
if (application != NULL) {
+ prompt = _("Open Failed, would you like to choose another application?");
message = g_strdup_printf (_("\"%s\" can't open \"%s\" because \"%s\" can't access files at \"%s\" "
- "locations. Would you like to choose another application?"),
+ "locations."),
application->name, file_name,
application->name, uri_scheme);
} else {
+ prompt = _("Open Failed, would you like to choose another action?");
message = g_strdup_printf (_("The default action can't open \"%s\" because it can't access files at \"%s\" "
- "locations. Would you like to choose another action?"),
+ "locations."),
file_name, uri_scheme);
}
- message_dialog = eel_show_yes_no_dialog (message,
+ message_dialog = eel_show_yes_no_dialog (prompt,
+ message,
_("Can't Open Location"),
GTK_STOCK_OK,
GTK_STOCK_CANCEL,
@@ -528,26 +532,28 @@ application_cannot_open_location (GnomeVFSMimeApplication *application,
launch_parameters);
}
-
+ g_free (message);
} else {
if (application != NULL) {
- message = g_strdup_printf (_("\"%s\" can't open \"%s\" because \"%s\" can't access files at \"%s\" "
- "locations. No other applications are available to view this file. "
- "If you copy this file onto your computer, you may be able to open "
- "it."), application->name, file_name,
- application->name, uri_scheme);
+ prompt = g_strdup_printf (_("\"%s\" can't open \"%s\" because \"%s\" can't access files at \"%s\"."
+ "locations."), application->name, file_name,
+ application->name, uri_scheme);
+ message = _("No other applications are available to view this file. "
+ "If you copy this file onto your computer, you may be able to open "
+ "it.");
} else {
- message = g_strdup_printf (_("The default action can't open \"%s\" because it can't access files at \"%s\" "
- "locations. No other actions are available to view this file. "
- "If you copy this file onto your computer, you may be able to open "
- "it."), file_name, uri_scheme);
+ prompt = g_strdup_printf (_("The default action can't open \"%s\" because it can't access files at \"%s\"."
+ "locations."), file_name, uri_scheme);
+ message = _("No other actions are available to view this file. "
+ "If you copy this file onto your computer, you may be able to open "
+ "it.");
}
- eel_show_info_dialog (message, _("Can't Open Location"), parent_window);
+ eel_show_info_dialog (prompt, message, _("Can't Open Location"), parent_window);
+ g_free (prompt);
}
g_free (file_name);
- g_free (message);
}
#ifdef HAVE_STARTUP_NOTIFICATION
@@ -1159,8 +1165,9 @@ nautilus_launch_desktop_file (GdkScreen *screen,
EEL_VFS_CAPABILITY_SAFE_TO_EXECUTE)) {
eel_show_error_dialog
(_("Sorry, but you can't execute commands from "
- "a remote site due to security considerations."),
- _("Can't execute remote links"),
+ "a remote site."),
+ _("This is disabled due to security considerations."),
+ _("Can't Execute Remote Links"),
parent_window);
return;
@@ -1170,11 +1177,11 @@ nautilus_launch_desktop_file (GdkScreen *screen,
ditem = gnome_desktop_item_new_from_uri (desktop_file_uri, 0,
&error);
if (error != NULL) {
- message = g_strconcat (_("There was an error launching the application.\n\n"
- "Details: "), error->message, NULL);
+ message = g_strconcat (_("Details: "), error->message, NULL);
eel_show_error_dialog
- (message,
- _("Error launching application"),
+ (_("There was an error launching the application."),
+ message,
+ _("Error Launching Application"),
parent_window);
g_error_free (error);
@@ -1202,10 +1209,10 @@ nautilus_launch_desktop_file (GdkScreen *screen,
if (count == 0) {
/* all files are non-local */
eel_show_error_dialog
- (_("This drop target only supports local files.\n\n"
- "To open non-local files copy them to a local folder and then"
+ (_("This drop target only supports local files."),
+ _("To open non-local files copy them to a local folder and then"
" drop them again."),
- _("Drop target only supports local files"),
+ _("Drop Target Only Supports Local Files"),
parent_window);
gnome_desktop_item_unref (ditem);
@@ -1214,10 +1221,10 @@ nautilus_launch_desktop_file (GdkScreen *screen,
} else if (count != total) {
/* some files were non-local */
eel_show_warning_dialog
- (_("This drop target only supports local files.\n\n"
- "To open non-local files copy them to a local folder and then"
+ (_("This drop target only supports local files."),
+ _("To open non-local files copy them to a local folder and then"
" drop them again. The local files you dropped have already been opened."),
- _("Drop target only supports local files"),
+ _("Drop Target Only Supports Local Files"),
parent_window);
}
}
@@ -1236,11 +1243,11 @@ nautilus_launch_desktop_file (GdkScreen *screen,
flags, envp,
&error);
if (error != NULL) {
- message = g_strconcat (_("There was an error launching the application.\n\n"
- "Details: "), error->message, NULL);
+ message = g_strconcat (_("Details: "), error->message, NULL);
eel_show_error_dialog
- (message,
- _("Error launching application"),
+ (_("There was an error launching the application."),
+ message,
+ _("Error Launching Application"),
parent_window);
g_error_free (error);
diff --git a/src/file-manager/fm-directory-view.c b/src/file-manager/fm-directory-view.c
index 18a124655..764e1e1ac 100644
--- a/src/file-manager/fm-directory-view.c
+++ b/src/file-manager/fm-directory-view.c
@@ -488,19 +488,20 @@ fm_directory_view_confirm_multiple_windows (FMDirectoryView *view, int count)
GtkDialog *dialog;
char *prompt;
char *title;
+ char *detail;
int response;
if (count <= SILENT_WINDOW_OPEN_LIMIT) {
return TRUE;
}
- prompt = g_strdup_printf (_("This will open %d separate windows. "
- "Are you sure you want to do this?"), count);
title = g_strdup_printf (_("Open %d Windows?"), count);
- dialog = eel_show_yes_no_dialog (prompt, title,
+ prompt = _("Are you sure you want to open all files?");
+ detail = g_strdup_printf (_("This will open %d separate windows."), count);
+ dialog = eel_show_yes_no_dialog (prompt, detail, title,
GTK_STOCK_OK, GTK_STOCK_CANCEL,
fm_directory_view_get_containing_window (view));
- g_free (prompt);
+ g_free (detail);
g_free (title);
response = gtk_dialog_run (dialog);
@@ -843,6 +844,7 @@ confirm_delete_directly (FMDirectoryView *view,
dialog = eel_show_yes_no_dialog
(prompt,
+ _("If you delete an item, it is permanently lost."),
_("Delete?"), GTK_STOCK_DELETE, GTK_STOCK_CANCEL,
fm_directory_view_get_containing_window (view));
@@ -1804,14 +1806,14 @@ real_file_limit_reached (FMDirectoryView *view)
* no more than the constant limit are displayed.
*/
message = g_strdup_printf (_("The folder \"%s\" contains more files than "
- "Nautilus can handle. Some files will not be "
- "displayed."),
+ "Nautilus can handle."),
directory_name);
g_free (directory_name);
dialog = eel_show_warning_dialog (message,
- _("Too Many Files"),
- fm_directory_view_get_containing_window (view));
+ _("Some files will not be displayed."),
+ _("Too Many Files"),
+ fm_directory_view_get_containing_window (view));
g_free (message);
}
@@ -3043,6 +3045,7 @@ fm_directory_view_confirm_deletion (FMDirectoryView *view, GList *uris, gboolean
{
GtkDialog *dialog;
char *prompt;
+ char *detail;
int uri_count;
char *file_name;
int response;
@@ -3054,28 +3057,25 @@ fm_directory_view_confirm_deletion (FMDirectoryView *view, GList *uris, gboolean
if (uri_count == 1) {
file_name = file_name_from_uri ((char *) uris->data);
-
- prompt = g_strdup_printf (_("\"%s\" cannot be moved to the Trash. Do "
- "you want to delete it immediately?"), file_name);
+ prompt = _("Cannot move file to trash, do you want to delete immediately?");
+ detail = g_strdup_printf (_("The file \"%s\" cannot be moved to the trash."), file_name);
g_free (file_name);
} else {
if (all) {
- prompt = g_strdup_printf (_("The %d selected items cannot be moved "
- "to the Trash. Do you want to delete them "
- "immediately?"), uri_count);
+ prompt = _("Cannot move items to trash, do you want to delete them immediately?");
+ detail = g_strdup_printf ("None of the %d selected items can be moved to the Trash", uri_count);
} else {
- prompt = g_strdup_printf (_("%d of the selected items cannot be moved "
- "to the Trash. Do you want to delete those "
- "%d items immediately?"), uri_count, uri_count);
+ prompt = _("Cannot move some items to trash, do you want to delete these immediately?");
+ detail = g_strdup_printf ("%d of the selected items cannot be moved to the Trash", uri_count);
}
}
dialog = eel_show_yes_no_dialog
(prompt,
- _("Delete Immediately?"), GTK_STOCK_DELETE, GTK_STOCK_CANCEL,
+ detail, _("Delete Immediately?"), GTK_STOCK_DELETE, GTK_STOCK_CANCEL,
fm_directory_view_get_containing_window (view));
- g_free (prompt);
+ g_free (detail);
response = gtk_dialog_run (dialog);
gtk_object_destroy (GTK_OBJECT (dialog));
@@ -3105,15 +3105,15 @@ confirm_delete_from_trash (FMDirectoryView *view, GList *uris)
if (uri_count == 1) {
file_name = file_name_from_uri ((char *) uris->data);
prompt = g_strdup_printf (_("Are you sure you want to permanently delete \"%s\" "
- "from the Trash?"), file_name);
+ "from the trash?"), file_name);
g_free (file_name);
} else {
prompt = g_strdup_printf (_("Are you sure you want to permanently delete "
- "the %d selected items from the Trash?"), uri_count);
+ "the %d selected items from the trash?"), uri_count);
}
dialog = eel_show_yes_no_dialog (
- prompt,
+ prompt, _("If you delete an item, it will be permanently lost."),
_("Delete From Trash?"), GTK_STOCK_DELETE, GTK_STOCK_CANCEL,
fm_directory_view_get_containing_window (view));
@@ -4377,7 +4377,8 @@ open_scripts_folder_callback (BonoboUIComponent *component,
eel_show_info_dialog_with_details
(_("All executable files in this folder will appear in the "
- "Scripts menu. Choosing a script from the menu will run "
+ "Scripts menu."),
+ _("Choosing a script from the menu will run "
"that script with any selected items as input."),
_("About Scripts"),
_("All executable files in this folder will appear in the "
@@ -4705,7 +4706,8 @@ drive_mounted_callback (gboolean succeeded,
gpointer data)
{
if (!succeeded) {
- eel_show_error_dialog_with_details (error, _("Mount Error"), detailed_error, NULL);
+ eel_show_error_dialog_with_details (error, NULL,
+ _("Mount Error"), detailed_error, NULL);
}
}
@@ -4766,9 +4768,11 @@ volume_or_drive_unmounted_callback (gboolean succeeded,
eject = GPOINTER_TO_INT (data);
if (!succeeded) {
if (eject) {
- eel_show_error_dialog_with_details (error, _("Unmount Error"), detailed_error, NULL);
+ eel_show_error_dialog_with_details (error, NULL,
+ _("Unmount Error"), detailed_error, NULL);
} else {
- eel_show_error_dialog_with_details (error, _("Eject Error"), detailed_error, NULL);
+ eel_show_error_dialog_with_details (error, NULL,
+ _("Eject Error"), detailed_error, NULL);
}
}
}
@@ -5378,6 +5382,7 @@ report_broken_symbolic_link (FMDirectoryView *view, NautilusFile *file)
{
char *target_path;
char *prompt;
+ char *detail;
GtkDialog *dialog;
GList file_as_list;
int response;
@@ -5385,17 +5390,16 @@ report_broken_symbolic_link (FMDirectoryView *view, NautilusFile *file)
g_assert (nautilus_file_is_broken_symbolic_link (file));
target_path = nautilus_file_get_symbolic_link_target_path (file);
+ prompt = _("The link is borken, do you want to move it to the Trash?");
if (target_path == NULL) {
- prompt = g_strdup_printf (_("This link can't be used, because it has no target. "
- "Do you want to move this link to the Trash?"));
+ detail = g_strdup (_("This link can't be used, because it has no target."));
} else {
- prompt = g_strdup_printf (_("This link can't be used, because its target \"%s\" doesn't exist. "
- "Do you want to move this link to the Trash?"),
- target_path);
+ detail = g_strdup_printf (_("This link can't be used, because its target "
+ "\"%s\" doesn't exist."), target_path);
}
dialog = eel_show_yes_no_dialog (prompt,
- _("Broken Link"), _("Mo_ve to Trash"), GTK_STOCK_CANCEL,
+ detail, _("Broken Link"), _("Mo_ve to Trash"), GTK_STOCK_CANCEL,
fm_directory_view_get_containing_window (view));
gtk_dialog_set_default_response (dialog, GTK_RESPONSE_YES);
@@ -5420,7 +5424,7 @@ report_broken_symbolic_link (FMDirectoryView *view, NautilusFile *file)
}
g_free (target_path);
- g_free (prompt);
+ g_free (detail);
}
static ActivationAction
@@ -5429,6 +5433,7 @@ get_executable_text_file_action (FMDirectoryView *view, NautilusFile *file)
GtkDialog *dialog;
char *file_name;
char *prompt;
+ char *detail;
int preferences_value;
int response;
@@ -5452,21 +5457,25 @@ get_executable_text_file_action (FMDirectoryView *view, NautilusFile *file)
file_name = nautilus_file_get_display_name (file);
- prompt = g_strdup_printf (_("\"%s\" is an executable text file. "
- "Do you want to run it, or display its contents?"),
- file_name);
+ prompt = g_strdup_printf (_("Do you want to run \"%s\", or display its contents?"),
+ file_name);
+ detail = g_strdup_printf (_("\"%s\" is an executable text file."),
+ file_name);
g_free (file_name);
dialog = eel_create_question_dialog (prompt,
+ detail,
_("Run or Display?"),
- _("_Display"), RESPONSE_DISPLAY,
_("Run in _Terminal"), RESPONSE_RUN_IN_TERMINAL,
+ _("_Display"), RESPONSE_DISPLAY,
fm_directory_view_get_containing_window (view));
gtk_dialog_add_button (dialog, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL);
gtk_dialog_add_button (dialog, _("_Run"), RESPONSE_RUN);
+ gtk_dialog_set_default_response (dialog, GTK_RESPONSE_CANCEL);
gtk_widget_show (GTK_WIDGET (dialog));
g_free (prompt);
+ g_free (detail);
response = gtk_dialog_run (dialog);
gtk_object_destroy (GTK_OBJECT (dialog));
@@ -5591,7 +5600,10 @@ activation_drive_mounted_callback (gboolean succeeded,
} else {
if (!parameters->cancelled) {
eel_timed_wait_stop (cancel_activate_callback, parameters);
- eel_show_error_dialog_with_details (error, _("Mount Error"), detailed_error, NULL);
+ eel_show_error_dialog_with_details (error, NULL,
+ _("Mount Error"),
+ detailed_error,
+ NULL);
}
nautilus_file_unref (parameters->file);
@@ -5722,7 +5734,7 @@ fm_directory_view_activate_file (FMDirectoryView *view,
parameters->cancelled = FALSE;
file_name = nautilus_file_get_display_name (file);
- timed_wait_prompt = g_strdup_printf (_("Opening \"%s\""), file_name);
+ timed_wait_prompt = g_strdup_printf (_("Opening \"%s\"."), file_name);
g_free (file_name);
eel_timed_wait_start
diff --git a/src/file-manager/fm-error-reporting.c b/src/file-manager/fm-error-reporting.c
index 48167add6..09d22c33e 100644
--- a/src/file-manager/fm-error-reporting.c
+++ b/src/file-manager/fm-error-reporting.c
@@ -68,7 +68,8 @@ fm_report_error_loading_directory (NautilusFile *file,
message = g_strdup_printf (_("Sorry, couldn't display all the contents of \"%s\"."), file_name);
}
- eel_show_error_dialog (message, _("Error Displaying Folder"), parent_window);
+ eel_show_error_dialog (_("The folder contents could not be displayed."), message,
+ _("Error Displaying Folder"), parent_window);
g_free (file_name);
g_free (message);
@@ -140,7 +141,8 @@ fm_report_error_renaming_file (NautilusFile *file,
g_free (original_name_truncated);
g_free (new_name_truncated);
- eel_show_error_dialog (message, _("Renaming Error"), parent_window);
+ eel_show_error_dialog (_("The item could not be renamed."), message,
+ _("Renaming Error"), parent_window);
g_free (message);
}
@@ -176,7 +178,7 @@ fm_report_error_setting_group (NautilusFile *file,
g_free (file_name);
}
- eel_show_error_dialog (message, _("Error Setting Group"), parent_window);
+ eel_show_error_dialog (_("The group could not be changed."), message , _("Error Setting Group"), parent_window);
g_free (file_name);
g_free (message);
@@ -208,7 +210,7 @@ fm_report_error_setting_owner (NautilusFile *file,
message = g_strdup_printf (_("Sorry, couldn't change the owner of \"%s\"."), file_name);
}
- eel_show_error_dialog (message, _("Error Setting Owner"), parent_window);
+ eel_show_error_dialog (_("The owner could not be changed."), message, _("Error Setting Owner"), parent_window);
g_free (file_name);
g_free (message);
@@ -240,7 +242,8 @@ fm_report_error_setting_permissions (NautilusFile *file,
message = g_strdup_printf (_("Sorry, couldn't change the permissions of \"%s\"."), file_name);
}
- eel_show_error_dialog (message, _("Error Setting Permissions"), parent_window);
+ eel_show_error_dialog (_("The permissions could not be changed."), message,
+ _("Error Setting Permissions"), parent_window);
g_free (file_name);
g_free (message);
diff --git a/src/file-manager/fm-icon-view.c b/src/file-manager/fm-icon-view.c
index f2e66989c..e0f164de3 100644
--- a/src/file-manager/fm-icon-view.c
+++ b/src/file-manager/fm-icon-view.c
@@ -2541,8 +2541,9 @@ icon_view_handle_uri_list (NautilusIconContainer *container, const char *item_ur
if (eel_vfs_has_capability (container_uri,
EEL_VFS_CAPABILITY_IS_REMOTE_AND_SLOW)) {
- eel_show_warning_dialog (_("Drag and drop is only supported to local file systems."),
- _("Drag and Drop error"),
+ eel_show_warning_dialog (_("Drag and drop is not supported."),
+ _("Drag and drop is only supported on local file systems."),
+ _("Drag and Drop Error"),
fm_directory_view_get_containing_window (FM_DIRECTORY_VIEW (view)));
g_free (container_uri);
return;
@@ -2564,8 +2565,9 @@ icon_view_handle_uri_list (NautilusIconContainer *container, const char *item_ur
(action != GDK_ACTION_COPY) &&
(action != GDK_ACTION_MOVE) &&
(action != GDK_ACTION_LINK)) {
- eel_show_warning_dialog (_("An invalid drag type was used."),
- _("Drag and Drop error"),
+ eel_show_warning_dialog (_("Drag and drop is not supported."),
+ _("An invalid drag type was used."),
+ _("Drag and Drop Error"),
fm_directory_view_get_containing_window (FM_DIRECTORY_VIEW (view)));
g_free (container_uri);
return;
diff --git a/src/file-manager/fm-properties-window.c b/src/file-manager/fm-properties-window.c
index 51849cd19..b77b791f2 100644
--- a/src/file-manager/fm-properties-window.c
+++ b/src/file-manager/fm-properties-window.c
@@ -479,8 +479,8 @@ fm_properties_window_drag_data_received (GtkWidget *widget, GdkDragContext *cont
if (!exactly_one) {
eel_show_error_dialog
- (_("You can't assign more than one custom icon at a time! "
- "Please drag just one image to set a custom icon."),
+ (_("You can't assign more than one custom icon at a time!"),
+ _("Please drag just one image to set a custom icon."),
_("More Than One Image"),
window);
} else {
@@ -490,15 +490,15 @@ fm_properties_window_drag_data_received (GtkWidget *widget, GdkDragContext *cont
} else {
if (eel_is_remote_uri (uris[0])) {
eel_show_error_dialog
- (_("The file that you dropped is not local. "
- "You can only use local images as custom icons."),
+ (_("The file that you dropped is not local."),
+ _("You can only use local images as custom icons."),
_("Local Images Only"),
window);
} else {
eel_show_error_dialog
- (_("The file that you dropped is not an image. "
- "You can only use local images as custom icons."),
+ (_("The file that you dropped is not an image."),
+ _("You can only use local images as custom icons."),
_("Images Only"),
window);
}
@@ -1381,7 +1381,7 @@ activate_group_callback (GtkMenuItem *menu_item, FileNamePair *pair)
(cancel_group_change_callback,
pair->file,
_("Cancel Group Change?"),
- _("Changing group"),
+ _("Changing group."),
NULL); /* FIXME bugzilla.gnome.org 42397: Parent this? */
nautilus_file_set_group
(pair->file, pair->name,
@@ -1543,7 +1543,7 @@ activate_owner_callback (GtkMenuItem *menu_item, FileNamePair *pair)
(cancel_owner_change_callback,
pair->file,
_("Cancel Owner Change?"),
- _("Changing owner"),
+ _("Changing owner."),
NULL); /* FIXME bugzilla.gnome.org 42397: Parent this? */
nautilus_file_set_owner
(pair->file, pair->name,
@@ -3339,19 +3339,15 @@ static void
help_button_callback (GtkWidget *widget, GtkWidget *property_window)
{
GError *error = NULL;
- char *message;
egg_help_display_desktop_on_screen (NULL, "user-guide", "wgosnautilus.xml", "gosnautilus-51",
gtk_window_get_screen (GTK_WINDOW (property_window)),
&error);
if (error) {
- message = g_strdup_printf (_("There was an error displaying help: \n%s"),
- error->message);
- eel_show_error_dialog (message, _("Couldn't show help"),
+ eel_show_error_dialog (_("There was an error displaying help."), error->message, _("Couldn't Show Help"),
GTK_WINDOW (property_window));
g_error_free (error);
- g_free (message);
}
}
@@ -3686,7 +3682,7 @@ fm_properties_window_present (GList *original_files,
(cancel_create_properties_window_callback,
startup_data,
_("Cancel Showing Properties Window?"),
- _("Creating Properties window"),
+ _("Creating Properties window."),
parent_window == NULL ? NULL : GTK_WINDOW (parent_window));
diff --git a/src/file-manager/fm-search-list-view.c b/src/file-manager/fm-search-list-view.c
index 682daa757..8b43400fc 100644
--- a/src/file-manager/fm-search-list-view.c
+++ b/src/file-manager/fm-search-list-view.c
@@ -163,8 +163,9 @@ load_location_callback (NautilusView *nautilus_view, char *location)
}
}
#else
- eel_show_error_dialog (_("Sorry, but the Medusa search service is not available because it is not installed."),
- _("Search Service Not Available"),
+ eel_show_error_dialog (_("Sorry, but the Medusa search service is not available."),
+ _("Medusa is not installed."),
+ _("Search Service Not Available"),
NULL);
#endif
@@ -179,7 +180,6 @@ real_load_error (FMDirectoryView *nautilus_view,
GnomeVFSResult result)
{
GtkDialog *load_error_dialog;
- char *error_string;
/* Do not call parent's function; we handle all search errors
* here and don't want fm-directory-view's default handling.
@@ -190,42 +190,38 @@ real_load_error (FMDirectoryView *nautilus_view,
load_error_dialog = eel_show_info_dialog (_("The search you have selected "
"is newer than the index on your "
"system. The search will return "
- "no results right now. You can create a new "
- " index by running \"medusa-indexd\" as root "
+ "no results right now."),
+ _("You can create a new "
+ "index by running \"medusa-indexd\" as root "
"on the command line."),
- _("Search for items that are too new"),
+ _("Search For Items That Are Too New"),
NULL);
break;
case GNOME_VFS_ERROR_TOO_BIG:
eel_show_error_dialog (_("Every indexed file on your computer "
- "matches the criteria you selected. "
- "You can check the spelling on your selections "
+ "matches the criteria you selected. "),
+ _("You can check the spelling on your selections "
"or add more criteria to narrow your results."),
- _("Error during search"),
+ _("Error During Search"),
NULL);
break;
case GNOME_VFS_ERROR_SERVICE_NOT_AVAILABLE:
/* FIXME: This dialog does not get shown because a slow search
will be performed and will not return an error. */
eel_show_error_dialog (_("Find cannot open your file system index. "
- "Your index may be missing or corrupt. You can "
- "create a new index by running \"medusa-indexd\" as root "
+ "Your index may be missing or corrupt."),
+ _("You can create a new index by running \"medusa-indexd\" as root "
"on the command line."),
- _("Error reading file index"),
+ _("Error Reading File Index"),
NULL);
break;
case GNOME_VFS_ERROR_CANCELLED:
break;
default:
- error_string = g_strdup_printf (_("An error occurred while loading "
- "this search's contents: "
- "%s"),
- gnome_vfs_result_to_string (result));
- eel_show_error_dialog (error_string,
- _("Error during search"),
- NULL);
- g_free (error_string);
-
+ eel_show_error_dialog (_("An error occurred while loading this search's contents."),
+ gnome_vfs_result_to_string (result),
+ _("Error During Search"),
+ NULL);
}
}
@@ -234,7 +230,7 @@ real_load_error (FMDirectoryView *nautilus_view,
static void
display_indexed_search_problems_dialog (gboolean backup_search_is_available)
{
- const char *error_string, *title_string;
+ const char *error_string, *detail_string, *title_string;
if (medusa_indexed_search_system_index_files_look_available ()) {
/* There is an index on the system, but there is no
@@ -242,17 +238,19 @@ display_indexed_search_problems_dialog (gboolean backup_search_is_available)
confused. Tell the user this. */
error_string = backup_search_is_available
? N_("To do a fast search, Find requires an index "
- "of the files on your system. "
- "Find can't access your index right now "
+ "of the files on your system.")
+ : N_("To do a content search, Find requires an index "
+ "of the files on your system.");
+ detail_string = backup_search_is_available
+ ? N_("Find can't access your index right now "
"so a slower search will be performed that "
"doesn't use the index.")
- : N_("To do a content search, Find requires an index "
- "of the files on your system. "
- "Find can't access your index right now. ");
+ : N_("Find can't access your index right now.");
title_string = backup_search_is_available
- ? N_("Fast searches are not available")
- : N_("Content searches are not available");
+ ? N_("Fast Searches Are Not Available")
+ : N_("Content Searches Are Not Available");
eel_show_error_dialog_with_details (error_string,
+ detail_string,
title_string,
_("Your index files are available "
"but the Medusa search daemon, which handles "
@@ -270,19 +268,23 @@ display_indexed_search_problems_dialog (gboolean backup_search_is_available)
error_string = backup_search_is_available
? N_("To do a fast search, Find requires an index "
"of the files on your system. "
- "Your computer is currently creating that "
- "index. Because Find cannot use an index, "
- "this search may take several "
- "minutes.")
+ "Your computer is currently creating that "
+ "index.")
: N_("To do a content search, Find requires an index "
"of the content on your system. "
"Your computer is currently creating that "
- "index. Content searches will be available "
+ "index.");
+ detail_string = backup_search_is_available
+ ? N_("Because Find cannot use an index, "
+ "this search may take several "
+ "minutes.")
+ : N_("Content searches will be available "
"when the index is complete.");
title_string = backup_search_is_available
- ? N_("Indexed searches are not available")
- : N_("Content searches are not available");
+ ? N_("Indexed Searches Are Not Available")
+ : N_("Content Searches Are Not Available");
eel_show_error_dialog (error_string,
+ detail_string,
title_string,
NULL);
}
@@ -290,22 +292,26 @@ display_indexed_search_problems_dialog (gboolean backup_search_is_available)
error_string = backup_search_is_available
? N_("To do a fast search, Find requires an index "
"of the files on your system. No index "
- "is available right now. You can create an "
+ "is available right now.")
+ : N_("To do a content search, Find requires an index "
+ "of the content on your system. No index is "
+ "available right now.");
+ detail_string = backup_search_is_available
+ ? N_("You can create an "
"index by running \"medusa-indexd\" as root "
"on the command line. Until a complete index "
"is available, searches will "
"take several minutes.")
- : N_("To do a content search, Find requires an index "
- "of the content on your system. No index is "
- "available right now. You can create an "
+ : N_("You can create an "
"index by running \"medusa-indexd\" as root "
"on the command line. Until a complete index "
"is available, content searches cannot be "
"performed.");
title_string = backup_search_is_available
- ? N_("Indexed searches are not available")
- : N_("Content searches are not available");
+ ? N_("Indexed Searches Are Not Available")
+ : N_("Content Searches Are Not Available");
eel_show_error_dialog (error_string,
+ detail_string,
title_string,
NULL);
}
@@ -320,11 +326,12 @@ display_system_services_are_disabled_dialog (gboolean unindexed_search_is_availa
char *details_string;
details_string = nautilus_medusa_get_explanation_of_enabling ();
- dialog_shown = eel_show_info_dialog_with_details (_("To do a fast search, Find requires an index of "
+ dialog_shown = eel_show_info_dialog_with_details (_("Fast searches are not enabled on your computer."),
+ _("To do a fast search, Find requires an index of "
"the files on your system. Your system administrator "
"has disabled fast search on your computer, so no index "
"is available."),
- _("Fast searches are not enabled on your computer"),
+ _("Fast Searches Not Enabled"),
details_string,
NULL);
g_free (details_string);
@@ -681,8 +688,8 @@ real_file_limit_reached (FMDirectoryView *view)
* to the way files are collected in batches. So you can't assume that
* no more than the constant limit are displayed.
*/
- eel_show_warning_dialog (_("Nautilus found more search results than it can display. "
- "Some matching items will not be displayed. "),
+ eel_show_warning_dialog (_("Nautilus found more search results than it can display."),
+ _("Some matching items will not be displayed. "),
_("Too Many Matches"),
fm_directory_view_get_containing_window (view));
}
diff --git a/src/file-manager/nautilus-indexing-info.c b/src/file-manager/nautilus-indexing-info.c
index f570856a3..85e445e12 100644
--- a/src/file-manager/nautilus-indexing-info.c
+++ b/src/file-manager/nautilus-indexing-info.c
@@ -161,23 +161,18 @@ last_index_time_dialog_new (void)
GtkWidget *label;
GtkDialog *dialog;
- dialog = eel_create_info_dialog (_("Once a day your files and text content are indexed so "
+ time_str = nautilus_indexing_info_get_last_index_time ();
+ label_str = g_strdup_printf (_("Your files were last indexed at %s."),
+ time_str);
+ g_free (time_str);
+
+ dialog = eel_create_info_dialog (label_str,
+ _("Once a day your files and text content are indexed so "
"your searches are fast. "),
_("Indexing Status"),
NULL);
set_close_hides_for_dialog (dialog);
- time_str = nautilus_indexing_info_get_last_index_time ();
- label_str = g_strdup_printf (_("Your files were last indexed at %s"),
- time_str);
- g_free (time_str);
-
- label = gtk_label_new (label_str);
- gtk_label_set_justify (GTK_LABEL (label), GTK_JUSTIFY_LEFT);
- eel_gtk_label_make_bold (GTK_LABEL (label));
- gtk_box_pack_start (GTK_BOX (dialog->vbox), label,
- FALSE, FALSE, 0);
-
return dialog;
}
@@ -199,8 +194,9 @@ index_progress_dialog_new (void)
ProgressChangeData *progress_data;
guint timeout_id;
- dialog = eel_create_info_dialog (_("Once a day your files and text content are indexed so "
- "your searches are fast. Your files are currently being indexed."),
+ dialog = eel_create_info_dialog (_("Your files are currently being indexed."),
+ _("Once a day your files and text content are indexed so "
+ "your searches are fast."),
_("Indexing Status"), NULL);
set_close_hides_for_dialog (dialog);
percentage_complete = get_index_percentage_complete ();
@@ -258,11 +254,12 @@ show_indexing_info_dialog (void)
if (!medusa_system_services_are_enabled ()) {
details_string = nautilus_medusa_get_explanation_of_enabling ();
- dialog_shown = eel_show_info_dialog_with_details (_("When Fast Search is enabled, Find creates an "
+ dialog_shown = eel_show_info_dialog_with_details (_("There is no index of your files right now."),
+ _("When Fast Search is enabled, Find creates an "
"index to speed up searches. Fast searching "
"is not enabled on your computer, so you "
"do not have an index right now."),
- _("There is no index of your files right now."),
+ _("No Index of Files"),
details_string,
NULL);
g_free (details_string);
@@ -300,6 +297,7 @@ static void
show_search_service_not_available_dialog (void)
{
eel_show_error_dialog (_("Sorry, but the medusa search service is not available."),
+ _("Please verify medusa has been setup correctly."),
_("Search Service Not Available"),
NULL);
}
diff --git a/src/nautilus-application.c b/src/nautilus-application.c
index 43ea9742e..b7f1f21fa 100644
--- a/src/nautilus-application.c
+++ b/src/nautilus-application.c
@@ -225,6 +225,7 @@ check_required_directories (NautilusApplication *application)
EelStringList *directories;
char *directories_as_string;
char *error_string;
+ char *detail_string;
char *dialog_title;
GtkDialog *dialog;
int failed_count;
@@ -249,30 +250,28 @@ check_required_directories (NautilusApplication *application)
failed_count = eel_string_list_get_length (directories);
if (failed_count != 0) {
- directories_as_string = eel_string_list_as_string (directories, "\n", EEL_STRING_LIST_ALL_STRINGS);
+ directories_as_string = eel_string_list_as_string (directories, ", ", EEL_STRING_LIST_ALL_STRINGS);
if (failed_count == 1) {
- dialog_title = g_strdup (_("Couldn't Create Required Folder"));
- error_string = g_strdup_printf (_("Nautilus could not create the required folder \"%s\". "
- "Before running Nautilus, please create this folder, or "
- "set permissions such that Nautilus can create it."),
+ dialog_title = _("Couldn't Create Required Folder");
+ error_string = g_strdup_printf (_("Nautilus could not create the required folder \"%s\"."),
directories_as_string);
+ detail_string = _("Before running Nautilus, please create the following folder, or "
+ "set permissions such that Nautilus can create it.");
} else {
- dialog_title = g_strdup (_("Couldn't Create Required Folders"));
- error_string = g_strdup_printf (_("Nautilus could not create the following required folders:\n\n"
- "%s\n\n"
- "Before running Nautilus, please create these folders, or "
- "set permissions such that Nautilus can create them."),
- directories_as_string);
+ dialog_title = _("Couldn't Create Required Folders");
+ error_string = g_strdup_printf (_("Nautilus could not create the following required folders: "
+ "%s."), directories_as_string);
+ detail_string = _("Before running Nautilus, please create these folders, or "
+ "set permissions such that Nautilus can create them.");
}
- dialog = eel_show_error_dialog (error_string, dialog_title, NULL);
+ dialog = eel_show_error_dialog (error_string, detail_string, dialog_title, NULL);
/* We need the main event loop so the user has a chance to see the dialog. */
nautilus_main_event_loop_register (GTK_OBJECT (dialog));
g_free (directories_as_string);
g_free (error_string);
- g_free (dialog_title);
}
eel_string_list_free (directories);
@@ -347,10 +346,10 @@ migrate_old_nautilus_files (void)
close (fd);
}
- eel_show_info_dialog (_("The location of the desktop directory has changed in GNOME 2.4. "
- "A link called \"Link To Old Desktop\" has been created on the desktop. "
- "You can open this to move over the files you want, then delete the link."),
- _("Migrated old desktop"),
+ eel_show_info_dialog (_("A link called \"Link To Old Desktop\" has been created on the desktop."),
+ _("The location of the desktop directory has changed in GNOME 2.4. "
+ "You can open the link and move over the files you want, then delete the link."),
+ _("Migrated Old Desktop"),
NULL);
}
g_free (old_desktop_dir);
@@ -590,7 +589,7 @@ nautilus_application_startup (NautilusApplication *application,
}
if (message != NULL) {
- dialog = eel_show_error_dialog_with_details (message, NULL, detailed_message, NULL);
+ dialog = eel_show_error_dialog_with_details (message, NULL, NULL, detailed_message, NULL);
/* We need the main event loop so the user has a chance to see the dialog. */
nautilus_main_event_loop_register (GTK_OBJECT (dialog));
goto out;
diff --git a/src/nautilus-connect-server-dialog.c b/src/nautilus-connect-server-dialog.c
index 8efdb525f..88eb941ad 100644
--- a/src/nautilus-connect-server-dialog.c
+++ b/src/nautilus-connect-server-dialog.c
@@ -83,7 +83,9 @@ connect_to_server (NautilusConnectServerDialog *dialog)
name = gtk_editable_get_chars (GTK_EDITABLE (dialog->details->name_entry), 0, -1);
if (strlen (name) == 0) {
- eel_show_error_dialog (_("You must enter a name for the server"), _("Can't connect to server"), GTK_WINDOW (dialog));
+ eel_show_error_dialog (_("You must enter a name for the server."),
+ _("Please enter a name and try again."),
+ _("Can't Connect to Server"), GTK_WINDOW (dialog));
g_free (name);
return;
}
@@ -96,9 +98,10 @@ connect_to_server (NautilusConnectServerDialog *dialog)
if (vfs_uri == NULL) {
error_message = g_strdup_printf
- (_("\"%s\" is not a valid location. Please check the spelling and try again."),
+ (_("\"%s\" is not a valid location."),
uri);
- eel_show_error_dialog (error_message, _("Can't connect to server"), GTK_WINDOW (dialog));
+ eel_show_error_dialog (error_message, _("Please check the spelling and try again."),
+ _("Can't Connect to Server"), GTK_WINDOW (dialog));
g_free (error_message);
} else {
gnome_vfs_uri_unref (vfs_uri);
diff --git a/src/nautilus-information-panel.c b/src/nautilus-information-panel.c
index b599150c8..4826bcf41 100644
--- a/src/nautilus-information-panel.c
+++ b/src/nautilus-information-panel.c
@@ -503,8 +503,8 @@ receive_dropped_uri_list (NautilusInformationPanel *information_panel,
if (!exactly_one) {
eel_show_error_dialog (
- _("You can't assign more than one custom icon at a time! "
- "Please drag just one image to set a custom icon."),
+ _("You can't assign more than one custom icon at a time."),
+ _("Please drag just one image to set a custom icon."),
_("More Than One Image"),
window);
break;
@@ -524,15 +524,15 @@ receive_dropped_uri_list (NautilusInformationPanel *information_panel,
} else {
if (eel_is_remote_uri (uris[0])) {
eel_show_error_dialog (
- _("The file that you dropped is not local. "
- "You can only use local images as custom icons."),
+ _("The file that you dropped is not local."),
+ _("You can only use local images as custom icons."),
_("Local Images Only"),
window);
} else {
eel_show_error_dialog (
- _("The file that you dropped is not an image. "
- "You can only use local images as custom icons."),
+ _("The file that you dropped is not an image."),
+ _("You can only use images as custom icons."),
_("Images Only"),
window);
}
@@ -982,7 +982,6 @@ burn_cd_callback (GtkWidget *button, gpointer data)
{
GError *error;
char *argv[] = { "nautilus-cd-burner", NULL};
- char *text;
error = NULL;
if (!g_spawn_async (NULL,
@@ -991,11 +990,9 @@ burn_cd_callback (GtkWidget *button, gpointer data)
NULL, NULL,
NULL,
&error)) {
- text = g_strdup_printf (_("Unable to launch the cd burner application:\n%s"), error->message);
- eel_show_error_dialog (text,
- _("Can't launch cd burner"),
+ eel_show_error_dialog (_("Unable to launch the cd burner application."), error->message,
+ _("Can't Launch CD Burner"),
GTK_WINDOW (gtk_widget_get_toplevel (button)));
- g_free (text);
g_error_free (error);
}
}
diff --git a/src/nautilus-location-bar.c b/src/nautilus-location-bar.c
index fd4092dfd..afbdda4c5 100644
--- a/src/nautilus-location-bar.c
+++ b/src/nautilus-location-bar.c
@@ -130,6 +130,7 @@ drag_data_received_callback (GtkWidget *widget,
GdkScreen *screen;
gboolean new_windows_for_extras;
char *prompt;
+ char *detail;
g_assert (NAUTILUS_IS_LOCATION_BAR (widget));
g_assert (data != NULL);
@@ -151,20 +152,24 @@ drag_data_received_callback (GtkWidget *widget,
*/
name_count = g_list_length (names);
if (name_count > 1) {
- prompt = g_strdup_printf (_("Do you want to view these %d locations "
- "in separate windows?"),
- name_count);
+ prompt = g_strdup_printf (_("Do you want to view %d locations?"),
+ name_count);
+ detail = g_strdup_printf (_("This will open %d separate windows."),
+ name_count);
/* eel_run_simple_dialog should really take in pairs
* like gtk_dialog_new_with_buttons() does. */
new_windows_for_extras = eel_run_simple_dialog
(GTK_WIDGET (window),
TRUE,
+ GTK_MESSAGE_QUESTION,
prompt,
+ detail,
_("View in Multiple Windows?"),
- GTK_STOCK_OK, GTK_STOCK_CANCEL,
- NULL) == 0 /* GNOME_OK */;
+ GTK_STOCK_CANCEL, GTK_STOCK_OK,
+ NULL) != 0 /* GNOME_OK */;
g_free (prompt);
+ g_free (detail);
if (!new_windows_for_extras) {
gtk_drag_finish (context, FALSE, FALSE, time);
diff --git a/src/nautilus-navigation-window-menus.c b/src/nautilus-navigation-window-menus.c
index 4d8055887..2c32d0cb5 100644
--- a/src/nautilus-navigation-window-menus.c
+++ b/src/nautilus-navigation-window-menus.c
@@ -174,6 +174,7 @@ forget_history_if_confirmed (NautilusWindow *window)
{
GtkDialog *dialog;
char *prompt;
+ char *detail;
/* Confirm before forgetting history because it's a rare operation that
* is hard to recover from. We don't want people doing it accidentally
@@ -183,22 +184,23 @@ forget_history_if_confirmed (NautilusWindow *window)
/* This is a little joke, shows up occasionally. I only
* implemented this feature so I could use this joke.
*/
- prompt = g_strdup (_("Are you sure you want to forget history? "
- "If you do, you will be doomed to repeat it."));
+ prompt = _("Are you sure you want to forget history?");
+ detail = _("If you do, you will be doomed to repeat it.");
} else {
- prompt = g_strdup (_("Are you sure you want to clear the list "
- "of locations you have visited?"));
+ prompt = _("Are you sure you want to clear the list "
+ "of locations you have visited?");
+ detail = _("If you clear the list of locations,"
+ " they will be permanently deleted.");
}
dialog = eel_create_question_dialog (prompt,
+ detail,
_("Clear History"),
GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
GTK_STOCK_CLEAR, RESPONSE_FORGET,
GTK_WINDOW (window));
gtk_widget_show (GTK_WIDGET (dialog));
-
- g_free (prompt);
g_signal_connect (dialog, "response",
G_CALLBACK (forget_history_if_yes), NULL);
@@ -417,14 +419,16 @@ show_bogus_bookmark_window (NautilusWindow *window,
char *uri;
char *uri_for_display;
char *prompt;
+ char *detail;
uri = nautilus_bookmark_get_uri (bookmark);
uri_for_display = eel_format_uri_for_display (uri);
- prompt = g_strdup_printf (_("The location \"%s\" does not exist. Do you "
- "want to remove any bookmarks with this "
- "location from your list?"), uri_for_display);
- dialog = eel_show_yes_no_dialog (prompt,
+ prompt = _("Do you want to remove any bookmarks with the "
+ "non-existing location from your list?");
+ detail = g_strdup_printf (_("The location \"%s\" does not exist."), uri_for_display);
+
+ dialog = eel_show_yes_no_dialog (prompt, detail,
_("Bookmark for Nonexistent Location"),
_("Remove"), GTK_STOCK_CANCEL,
GTK_WINDOW (window));
@@ -439,7 +443,7 @@ show_bogus_bookmark_window (NautilusWindow *window,
g_free (uri);
g_free (uri_for_display);
- g_free (prompt);
+ g_free (detail);
}
static void
diff --git a/src/nautilus-navigation-window.c b/src/nautilus-navigation-window.c
index 479686ee9..7df7380fe 100644
--- a/src/nautilus-navigation-window.c
+++ b/src/nautilus-navigation-window.c
@@ -1095,22 +1095,22 @@ static void
report_side_panel_failure_to_user (NautilusWindow *window, NautilusViewFrame *view_frame)
{
char *message;
+ char *detail;
char *label;
label = nautilus_window_get_view_frame_label (view_frame);
if (label == NULL) {
message = g_strdup
- (_("One of the side panels encountered an error and can't continue. "
- "Unfortunately I couldn't tell which one."));
+ (_("One of the side panels encountered an error and can't continue."));
+ detail = _("Unfortunately I couldn't tell which one.");
} else {
message = g_strdup_printf
- (_("The %s side panel encountered an error and can't continue. "
- "If this keeps happening, you might want to turn this panel off."),
- label);
+ (_("The %s side panel encountered an error and can't continue."), label);
+ detail = _("If this keeps happening, you might want to turn this panel off.");
}
- eel_show_error_dialog (message, _("Side Panel Failed"), GTK_WINDOW (window));
+ eel_show_error_dialog (message, detail, _("Side Panel Failed"), GTK_WINDOW (window));
g_free (label);
g_free (message);
diff --git a/src/nautilus-property-browser.c b/src/nautilus-property-browser.c
index 7bbb8720a..6aa1c957b 100644
--- a/src/nautilus-property-browser.c
+++ b/src/nautilus-property-browser.c
@@ -911,7 +911,8 @@ remove_pattern(NautilusPropertyBrowser *property_browser, const char* pattern_na
/* delete the pattern from the pattern directory */
if (gnome_vfs_unlink (pattern_uri) != GNOME_VFS_OK) {
char *message = g_strdup_printf (_("Sorry, but pattern %s couldn't be deleted."), pattern_name);
- eel_show_error_dialog (message, _("Couldn't delete pattern"), GTK_WINDOW (property_browser));
+ char *detail = _("Check that you have permission to delete the pattern.");
+ eel_show_error_dialog (message, detail, _("Couldn't Delete Pattern"), GTK_WINDOW (property_browser));
g_free (message);
}
@@ -940,7 +941,8 @@ remove_emblem (NautilusPropertyBrowser *property_browser, const char* emblem_nam
/* delete the emblem from the emblem directory */
if (gnome_vfs_unlink (emblem_uri) != GNOME_VFS_OK) {
char *message = g_strdup_printf (_("Sorry, but emblem %s couldn't be deleted."), emblem_name);
- eel_show_error_dialog (message, _("Couldn't delete pattern"), GTK_WINDOW (property_browser));
+ char *detail = _("Check that you have permission to delete the emblem.");
+ eel_show_error_dialog (message, detail, _("Couldn't Delete Emblem"), GTK_WINDOW (property_browser));
g_free (message);
}
else {
@@ -1097,12 +1099,15 @@ add_pattern_to_browser (const char *path_name, gpointer *data)
/* make sure that it's a valid path */
if (path_name == NULL || path_name[0] != '/') {
char *message;
+ char *detail;
if (path_name != NULL) {
message = g_strdup_printf (_("Sorry, but \"%s\" is not a valid file name."), path_name);
+ detail = _("Please check the spelling and try again.");
} else {
message = g_strdup (_("Sorry, but you did not supply a valid file name."));
+ detail = _("Please try again.");
}
- eel_show_error_dialog (message, _("Couldn't install pattern"), GTK_WINDOW (property_browser));
+ eel_show_error_dialog (message, detail, _("Couldn't Install Pattern"), GTK_WINDOW (property_browser));
g_free (message);
return;
}
@@ -1113,7 +1118,9 @@ add_pattern_to_browser (const char *path_name, gpointer *data)
/* don't allow the user to change the reset image */
basename = eel_uri_get_basename (path_uri);
if (basename && eel_strcmp (basename, RESET_IMAGE_NAME) == 0) {
- eel_show_error_dialog (_("Sorry, but you can't replace the reset image."), _("Not an Image"), NULL);
+ eel_show_error_dialog (_("Sorry, but you can't replace the reset image."),
+ _("Reset is a special image that cannot be deleted."),
+ _("Not an Image"), NULL);
g_free (path_uri);
g_free (basename);
return;
@@ -1145,7 +1152,7 @@ add_pattern_to_browser (const char *path_name, gpointer *data)
result = eel_copy_uri_simple (path_name, destination_name);
if (result != GNOME_VFS_OK) {
char *message = g_strdup_printf (_("Sorry, but the pattern %s couldn't be installed."), path_name);
- eel_show_error_dialog (message, _("Couldn't install pattern"), GTK_WINDOW (property_browser));
+ eel_show_error_dialog (message, NULL, _("Couldn't Install Pattern"), GTK_WINDOW (property_browser));
g_free (message);
}
@@ -1225,8 +1232,9 @@ add_color_to_browser (GtkWidget *widget, gint which_button, gpointer *data)
color_name = gtk_entry_get_text (GTK_ENTRY (property_browser->details->color_name));
stripped_color_name = g_strstrip (g_strdup (color_name));
if (strlen (stripped_color_name) == 0) {
- eel_show_error_dialog (_("Sorry, but you must specify a non-blank name for the new color."),
- _("Couldn't install color"), GTK_WINDOW (property_browser));
+ eel_show_error_dialog (_("The color cannot be installed."),
+ _("Sorry, but you must specify a non-blank name for the new color."),
+ _("Couldn't Install Color"), GTK_WINDOW (property_browser));
} else {
add_color_to_file (property_browser, color_spec, stripped_color_name);
@@ -1315,8 +1323,8 @@ emblem_dialog_clicked (GtkWidget *dialog, int which_button, NautilusPropertyBrow
property_browser->details->image_path = emblem_path;
} else {
char *message = g_strdup_printf
- (_("Sorry, but '%s' is not a usable image file!"), emblem_path);
- eel_show_error_dialog (message, _("Not an Image"), GTK_WINDOW (property_browser));
+ (_("Sorry, but \"%s\" is not a usable image file."), emblem_path);
+ eel_show_error_dialog (_("The file is not an image."), message, _("Not an Image"), GTK_WINDOW (property_browser));
g_free (message);
g_free (emblem_path);
return;
@@ -1331,8 +1339,9 @@ emblem_dialog_clicked (GtkWidget *dialog, int which_button, NautilusPropertyBrow
if (pixbuf == NULL) {
char *message = g_strdup_printf
- (_("Sorry, but '%s' is not a usable image file!"), property_browser->details->image_path);
- eel_show_error_dialog (message, _("Not an Image"), GTK_WINDOW (property_browser));
+ (_("Sorry, but \"%s\" is not a usable image file."), property_browser->details->image_path);
+ eel_show_error_dialog (_("The file is not an image."), message, _("Not an Image"), GTK_WINDOW (property_browser));
+ g_free (message);
}
new_keyword = gtk_entry_get_text(GTK_ENTRY(property_browser->details->keyword));
diff --git a/src/nautilus-window-manage-views.c b/src/nautilus-window-manage-views.c
index 439bc55a8..5667ffa89 100644
--- a/src/nautilus-window-manage-views.c
+++ b/src/nautilus-window-manage-views.c
@@ -808,13 +808,14 @@ view_frame_get_id (NautilusViewFrame *view_frame)
static void
report_content_view_failure_to_user_internal (NautilusWindow *window,
NautilusViewFrame *view_frame,
- const char *message)
+ const char *message,
+ const char *detail)
{
char *label;
label = nautilus_window_get_view_frame_label (view_frame);
message = g_strdup_printf (message, label);
- eel_show_error_dialog (message, _("View Failed"), GTK_WINDOW (window));
+ eel_show_error_dialog (message, detail, _("View Failed"), GTK_WINDOW (window));
g_free (label);
}
@@ -825,8 +826,8 @@ report_current_content_view_failure_to_user (NautilusWindow *window,
report_content_view_failure_to_user_internal
(window,
view_frame,
- _("The %s view encountered an error and can't continue. "
- "You can choose another view or go to a different location."));
+ _("The %s view encountered an error and can't continue."),
+ _("You can choose another view or go to a different location."));
}
static void
@@ -836,7 +837,8 @@ report_nascent_content_view_failure_to_user (NautilusWindow *window,
report_content_view_failure_to_user_internal
(window,
view_frame,
- _("The %s view encountered an error while starting up."));
+ _("The %s view encountered an error while starting up."),
+ _("The location cannot be displayed with this viewer."));
}
static void
@@ -1184,6 +1186,7 @@ determined_initial_view_callback (NautilusDetermineViewHandle *handle,
char *full_uri_for_display;
char *uri_for_display;
char *error_message;
+ char *detail_message;
char *scheme_string;
char *type_string;
char *dialog_title;
@@ -1237,14 +1240,18 @@ determined_initial_view_callback (NautilusDetermineViewHandle *handle,
case NAUTILUS_DETERMINE_VIEW_NOT_FOUND:
error_message = g_strdup_printf
- (_("Couldn't find \"%s\". Please check the spelling and try again."),
+ (_("Couldn't find \"%s\"."),
uri_for_display);
+ detail_message = g_strdup
+ (_("Please check the spelling and try again."));
break;
case NAUTILUS_DETERMINE_VIEW_INVALID_URI:
error_message = g_strdup_printf
- (_("\"%s\" is not a valid location. Please check the spelling and try again."),
+ (_("\"%s\" is not a valid location."),
uri_for_display);
+ detail_message = g_strdup
+ (_("Please check the spelling and try again."));
break;
case NAUTILUS_DETERMINE_VIEW_NO_HANDLER_FOR_TYPE:
@@ -1257,16 +1264,20 @@ determined_initial_view_callback (NautilusDetermineViewHandle *handle,
nautilus_file_unref (file);
if (type_string == NULL) {
error_message = g_strdup_printf
- (_("Couldn't display \"%s\", because Nautilus cannot determine what type of file it is."),
+ (_("Couldn't display \"%s\"."),
uri_for_display);
+ detail_message = g_strdup
+ (_("Nautilus cannot determine what type of file it is."));
} else {
/* FIXME bugzilla.gnome.org 44932:
* Should distinguish URIs with no handlers at all from remote URIs
* with local-only handlers.
*/
- error_message = g_strdup_printf
- (_("Nautilus has no installed viewer capable of displaying \"%s\"."),
- uri_for_display);
+ error_message = g_strdup_printf
+ (_("Couldn't display \"%s\"."),
+ uri_for_display);
+ detail_message = g_strdup
+ (_("Nautilus has no installed viewer capable of displaying the file."));
g_free (type_string);
}
break;
@@ -1277,19 +1288,23 @@ determined_initial_view_callback (NautilusDetermineViewHandle *handle,
*/
scheme_string = eel_str_get_prefix (location, ":");
g_assert (scheme_string != NULL); /* Shouldn't have gotten this error unless there's a : separator. */
- error_message = g_strdup_printf (_("Couldn't display \"%s\", because Nautilus cannot handle %s: locations."),
- uri_for_display, scheme_string);
+ error_message = g_strdup_printf (_("Couldn't display \"%s\"."),
+ uri_for_display);
+ detail_message = g_strdup_printf (_("Nautilus cannot handle %s: locations."),
+ scheme_string);
g_free (scheme_string);
break;
case NAUTILUS_DETERMINE_VIEW_LOGIN_FAILED:
- error_message = g_strdup_printf (_("Couldn't display \"%s\", because the attempt to log in failed."),
- uri_for_display);
+ error_message = g_strdup_printf (_("Couldn't display \"%s\"."),
+ uri_for_display);
+ detail_message = g_strdup (_("The attempt to log in failed."));
break;
case NAUTILUS_DETERMINE_VIEW_ACCESS_DENIED:
- error_message = g_strdup_printf (_("Couldn't display \"%s\", because access was denied."),
+ error_message = g_strdup_printf (_("Couldn't display \"%s\"."),
uri_for_display);
+ detail_message = g_strdup (_("Access was denied."));
break;
case NAUTILUS_DETERMINE_VIEW_HOST_NOT_FOUND:
@@ -1299,24 +1314,25 @@ determined_initial_view_callback (NautilusDetermineViewHandle *handle,
* the proxy is set up wrong.
*/
vfs_uri = gnome_vfs_uri_new (location);
- error_message = g_strdup_printf (_("Couldn't display \"%s\", because no host \"%s\" could be found. "
- "Check that the spelling is correct and that your proxy settings are correct."),
+ error_message = g_strdup_printf (_("Couldn't display \"%s\", because no host \"%s\" could be found."),
uri_for_display,
gnome_vfs_uri_get_host_name (vfs_uri));
+ detail_message = g_strdup (_("Check that the spelling is correct and that your proxy settings are correct."));
gnome_vfs_uri_unref (vfs_uri);
break;
case NAUTILUS_DETERMINE_VIEW_HOST_HAS_NO_ADDRESS:
- error_message = g_strdup_printf (_("Couldn't display \"%s\". "
- "Check that your proxy settings are correct."),
+ error_message = g_strdup_printf (_("Couldn't display \"%s\"."),
uri_for_display);
+ detail_message = g_strdup (_("Check that your proxy settings are correct."));
break;
case NAUTILUS_DETERMINE_VIEW_NO_MASTER_BROWSER:
error_message = g_strdup_printf
- (_("Couldn't display \"%s\", because Nautilus cannot contact the SMB master browser.\n"
- "Check that an SMB server is running in the local network."),
+ (_("Couldn't display \"%s\", because Nautilus cannot contact the SMB master browser."),
uri_for_display);
+ detail_message = g_strdup
+ (_("Check that an SMB server is running in the local network."));
break;
case NAUTILUS_DETERMINE_VIEW_SERVICE_NOT_AVAILABLE:
@@ -1327,8 +1343,9 @@ determined_initial_view_callback (NautilusDetermineViewHandle *handle,
*/
error_message = g_strdup_printf
(_("Searching is unavailable right now, because you either have no index, "
- "or the search service isn't running. "
- "Be sure that you have started the Medusa search service, and if you "
+ "or the search service isn't running."));
+ detail_message = g_strdup
+ (_("Be sure that you have started the Medusa search service, and if you "
"don't have an index, that the Medusa indexer is running."));
dialog_title = g_strdup (_("Searching Unavailable"));
break;
@@ -1337,6 +1354,7 @@ determined_initial_view_callback (NautilusDetermineViewHandle *handle,
default:
error_message = g_strdup_printf (_("Nautilus cannot display \"%s\"."),
uri_for_display);
+ detail_message = g_strdup (_("Please select another viewer and try again."));
}
if (dialog_title == NULL) {
@@ -1348,7 +1366,7 @@ determined_initial_view_callback (NautilusDetermineViewHandle *handle,
* happens when a new window cannot display its initial URI.
*/
- dialog = eel_show_error_dialog (error_message, dialog_title, NULL);
+ dialog = eel_show_error_dialog (error_message, detail_message, dialog_title, NULL);
/* if this is the only window, we don't want to quit, so we redirect it to home */
if (just_one_window ()) {
@@ -1377,7 +1395,7 @@ determined_initial_view_callback (NautilusDetermineViewHandle *handle,
} else {
/* Clean up state of already-showing window */
nautilus_window_allow_stop (window, FALSE);
- eel_show_error_dialog (error_message, dialog_title, GTK_WINDOW (window));
+ eel_show_error_dialog (error_message, detail_message, dialog_title, GTK_WINDOW (window));
/* Leave the location bar showing the bad location that the user
* typed (or maybe achieved by dragging or something). Many times
@@ -1389,6 +1407,7 @@ determined_initial_view_callback (NautilusDetermineViewHandle *handle,
g_free (dialog_title);
g_free (uri_for_display);
g_free (error_message);
+ g_free (detail_message);
}
/*
diff --git a/src/nautilus-window.c b/src/nautilus-window.c
index 44e894fff..09e5bdd66 100644
--- a/src/nautilus-window.c
+++ b/src/nautilus-window.c
@@ -473,7 +473,6 @@ nautilus_window_launch_cd_burner (NautilusWindow *window)
{
GError *error;
char *argv[] = { "nautilus-cd-burner", NULL};
- char *text;
error = NULL;
if (!g_spawn_async (NULL,
@@ -482,11 +481,9 @@ nautilus_window_launch_cd_burner (NautilusWindow *window)
NULL, NULL,
NULL,
&error)) {
- text = g_strdup_printf (_("Unable to launch the cd burner application:\n%s"), error->message);
- eel_show_error_dialog (text,
- _("Can't launch cd burner"),
+ eel_show_error_dialog (_("Unable to launch the cd burner application."), error->message,
+ _("Can't Launch CD Burner"),
GTK_WINDOW (window));
- g_free (text);
g_error_free (error);
}
}