aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2008-04-02 21:33:11 +0800
committerMilan Crha <mcrha@src.gnome.org>2008-04-02 21:33:11 +0800
commitee50e5d68e4f1a793541f1ee4979818ed4940173 (patch)
tree4fd9416ba68701e0362bc00c03176ce01a1b7025 /mail
parent20765294d7010414b64faeb247f66c40e3349569 (diff)
downloadgsoc2013-evolution-ee50e5d68e4f1a793541f1ee4979818ed4940173.tar.gz
gsoc2013-evolution-ee50e5d68e4f1a793541f1ee4979818ed4940173.tar.zst
gsoc2013-evolution-ee50e5d68e4f1a793541f1ee4979818ed4940173.zip
** Fix for bug #271863
2008-04-02 Milan Crha <mcrha@redhat.com> ** Fix for bug #271863 * mail-component.c: (view_changed): Do not count deleted junked messages to total number of messages with unchecked "Hide Deleted Messages" option. svn path=/trunk/; revision=35312
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog8
-rw-r--r--mail/mail-component.c5
2 files changed, 11 insertions, 2 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 49ab5045e8..f71ba1a4ea 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,11 @@
+2008-04-02 Milan Crha <mcrha@redhat.com>
+
+ ** Fix for bug #271863
+
+ * mail-component.c: (view_changed):
+ Do not count deleted junked messages to total number of messages
+ with unchecked "Hide Deleted Messages" option.
+
2008-04-01 Matthew Barnes <mbarnes@redhat.com>
** Fixes bug #525508, spotted by Thomas M.
diff --git a/mail/mail-component.c b/mail/mail-component.c
index 5a35245dea..34fcd26dc3 100644
--- a/mail/mail-component.c
+++ b/mail/mail-component.c
@@ -518,7 +518,7 @@ view_changed(EMFolderView *emfv, EComponentView *component_view)
if (emfv->folder) {
char *name, *title;
const char *use_name; /* will contain localized name, if necessary */
- guint32 visible, unread, deleted, junked;
+ guint32 visible, unread, deleted, junked, junked_not_deleted;
GPtrArray *selected;
GString *tmp = g_string_new("");
@@ -527,6 +527,7 @@ view_changed(EMFolderView *emfv, EComponentView *component_view)
CAMEL_FOLDER_DELETED, &deleted,
CAMEL_FOLDER_VISIBLE, &visible,
CAMEL_FOLDER_JUNKED, &junked,
+ CAMEL_FOLDER_JUNKED_NOT_DELETED, &junked_not_deleted,
CAMEL_FOLDER_UNREAD, &unread, NULL);
selected = message_list_get_selected(emfv->list);
@@ -552,7 +553,7 @@ view_changed(EMFolderView *emfv, EComponentView *component_view)
/* HACK: hardcoded inbox or maildir '.' folder */
} else {
if (!emfv->hide_deleted)
- visible += deleted;
+ visible += deleted - junked + junked_not_deleted;
if (unread && selected->len <= 1)
g_string_append_printf(tmp, ngettext ("%d unread, ", "%d unread, ", unread), unread);
g_string_append_printf(tmp, ngettext ("%d total", "%d total", visible), visible);