Mercurial > geeqie
diff src/utilops.c @ 223:73efc1ba150f
Setting no limit size to trash directory is now possible using zero as value.
A tooltip was added to the spinner to inform the user of this possibility.
When 0 is set, no remaining/free space check occurs.
Default size of the trash was set to a 128M and maximum size is now 2048MB, which
is more conform to today's standards.
The delete dialog now displays more information:
- if external command will be used
- if safe delete is on, max size and path to the trash
- if safe delete is off
author | zas_ |
---|---|
date | Thu, 03 Apr 2008 08:51:32 +0000 |
parents | f6e307c7bad6 |
children | 9faf34f047b1 |
line wrap: on
line diff
--- a/src/utilops.c Wed Apr 02 20:44:40 2008 +0000 +++ b/src/utilops.c Thu Apr 03 08:51:32 2008 +0000 @@ -1320,7 +1320,7 @@ total += fd->size; } - while (list && + while (safe_delete_size > 0 && list && (free_space < 0 || total + free_space > (gint64)safe_delete_size * 1048576) ) { FileData *fd; @@ -1449,7 +1449,29 @@ GtkWidget *label; gchar *buf; - buf = g_strdup_printf(_("Safe delete: %s"), (safe_delete_enable) ? _("on") : _("off")); + if (editor_command[CMD_DELETE]) + { + buf = g_strdup(_("Deletion by external command")); + } + else + { + if (safe_delete_enable) + { + gchar *buf2; + if (safe_delete_size > 0) + buf2 = g_strdup_printf(_(" (max. %d MB)"), safe_delete_size); + else + buf2 = g_strdup(""); + + buf = g_strdup_printf(_("Safe delete: %s%s\nTrash: %s"), _("on"), buf2, safe_delete_path); + g_free(buf2); + } + else + { + buf = g_strdup_printf(_("Safe delete: %s"), _("off")); + } + } + label = pref_label_new(gd->vbox, buf); g_free(buf);