mirror of
https://github.com/moparisthebest/k-9
synced 2024-11-02 00:25:10 -04:00
Keep track of UIDs when moving messages to the trash folder
This commit is contained in:
parent
c3885bc475
commit
f7299a69d4
@ -3515,6 +3515,7 @@ public class MessagingController implements Runnable {
|
||||
}
|
||||
Store localStore = account.getLocalStore();
|
||||
localFolder = localStore.getFolder(folder);
|
||||
Map<String, String> uidMap = null;
|
||||
if (folder.equals(account.getTrashFolderName()) || K9.FOLDER_NONE.equals(account.getTrashFolderName())) {
|
||||
if (K9.DEBUG)
|
||||
Log.d(K9.LOG_TAG, "Deleting messages in trash folder or trash set to -None-, not copying");
|
||||
@ -3529,7 +3530,7 @@ public class MessagingController implements Runnable {
|
||||
if (K9.DEBUG)
|
||||
Log.d(K9.LOG_TAG, "Deleting messages in normal folder, moving");
|
||||
|
||||
localFolder.moveMessages(messages, localTrashFolder);
|
||||
uidMap = localFolder.moveMessages(messages, localTrashFolder);
|
||||
|
||||
}
|
||||
}
|
||||
@ -3562,7 +3563,7 @@ public class MessagingController implements Runnable {
|
||||
if (folder.equals(account.getTrashFolderName())) {
|
||||
queueSetFlag(account, folder, Boolean.toString(true), Flag.DELETED.toString(), uids);
|
||||
} else {
|
||||
queueMoveOrCopy(account, folder, account.getTrashFolderName(), false, uids);
|
||||
queueMoveOrCopy(account, folder, account.getTrashFolderName(), false, uids, uidMap);
|
||||
}
|
||||
processPendingCommands(account);
|
||||
} else if (account.getDeletePolicy() == Account.DELETE_POLICY_MARK_AS_READ) {
|
||||
|
Loading…
Reference in New Issue
Block a user