aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2009-04-27 18:29:26 +0800
committerMilan Crha <mcrha@redhat.com>2009-04-27 18:29:26 +0800
commit59f095bfb5b92f8bd0205238f91fc3a2277de76c (patch)
treefe54cb1fef35ce895680e8f6edd78261877d1d71 /mail
parentd4def43e4d7fba2b8a123b7d11af8170b0f93a1b (diff)
downloadgsoc2013-evolution-59f095bfb5b92f8bd0205238f91fc3a2277de76c.tar
gsoc2013-evolution-59f095bfb5b92f8bd0205238f91fc3a2277de76c.tar.gz
gsoc2013-evolution-59f095bfb5b92f8bd0205238f91fc3a2277de76c.tar.bz2
gsoc2013-evolution-59f095bfb5b92f8bd0205238f91fc3a2277de76c.tar.lz
gsoc2013-evolution-59f095bfb5b92f8bd0205238f91fc3a2277de76c.tar.xz
gsoc2013-evolution-59f095bfb5b92f8bd0205238f91fc3a2277de76c.tar.zst
gsoc2013-evolution-59f095bfb5b92f8bd0205238f91fc3a2277de76c.zip
Hide last junked message too from the non-junk folder
** Fix for bug #579635
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog7
-rw-r--r--mail/message-list.c5
2 files changed, 10 insertions, 2 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 5bbf0366b5..586cb1b7bf 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,10 @@
+2009-04-27 Milan Crha <mcrha@redhat.com>
+
+ ** Fix for bug #579635
+
+ * message-list.c: (regen_list_exec): Do not keep last junked messages
+ in a message list for folders not showing junks.
+
2009-04-24 Milan Crha <mcrha@redhat.com>
** Fix for bug #579306
diff --git a/mail/message-list.c b/mail/message-list.c
index c98ce04ace..3027fcf3e8 100644
--- a/mail/message-list.c
+++ b/mail/message-list.c
@@ -4056,7 +4056,8 @@ regen_list_exec (struct _regen_list_msg *m)
CamelMessageInfo *looking_info = camel_folder_get_message_info (m->folder, looking_for);
if (looking_info) {
- gboolean was_deleted = (camel_message_info_flags (looking_info) & CAMEL_MESSAGE_DELETED) != 0;
+ gboolean is_deleted = (camel_message_info_flags (looking_info) & CAMEL_MESSAGE_DELETED) != 0;
+ gboolean is_junk = (camel_message_info_flags (looking_info) & CAMEL_MESSAGE_JUNK) != 0;
/* I would really like to check for CAMEL_MESSAGE_FOLDER_FLAGGED on a message,
so I would know whether it was changed locally, and then just check the changes
@@ -4064,7 +4065,7 @@ regen_list_exec (struct _regen_list_msg *m)
matter. So here just check whether the file was deleted and we show it based
on the flag whether we can view deleted messages or not. */
- if (!was_deleted || (was_deleted && !m->hidedel))
+ if ((!is_deleted || (is_deleted && !m->hidedel)) && (!is_junk || (is_junk && !m->hidejunk)))
g_ptr_array_add (uids, (gpointer) camel_pstring_strdup (looking_for));
camel_folder_free_message_info (m->folder, looking_info);