mirror of
https://github.com/moparisthebest/k-9
synced 2024-11-28 04:02:19 -05:00
Fixes Issue 1060
Don't show messages that are already deleted on the server when we first download them. Also, correct item 1 from my comments on r1355. No longer notify for mails I sent when I selected not to be notified for mails I sent.
This commit is contained in:
parent
9cd52d5ef3
commit
4f65b4270e
@ -1281,12 +1281,12 @@ public class MessagingController implements Runnable
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (!message.isSet(Flag.SEEN))
|
if (message.isSet(Flag.DELETED))
|
||||||
{
|
{
|
||||||
if (account.isNotifySelfNewMail() || account.isAnIdentity(message.getFrom()) == false)
|
if (K9.DEBUG)
|
||||||
{
|
Log.v(K9.LOG_TAG, "Newly downloaded message " + account + ":" + folder + ":" + message.getUid()
|
||||||
newMessages.incrementAndGet();
|
+ " was already deleted on server, skipping");
|
||||||
}
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Store the new message locally
|
// Store the new message locally
|
||||||
@ -1329,12 +1329,15 @@ public class MessagingController implements Runnable
|
|||||||
{
|
{
|
||||||
l.synchronizeMailboxAddOrUpdateMessage(account, folder, localMessage);
|
l.synchronizeMailboxAddOrUpdateMessage(account, folder, localMessage);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// Send a notification of this message
|
// Send a notification of this message
|
||||||
if (!message.isSet(Flag.SEEN))
|
if (!message.isSet(Flag.SEEN) &&
|
||||||
|
(account.isNotifySelfNewMail() || account.isAnIdentity(message.getFrom()) == false))
|
||||||
{
|
{
|
||||||
notifyAccount(mApplication, account, message);
|
notifyAccount(mApplication, account, message);
|
||||||
|
newMessages.incrementAndGet();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user