reworked LocalFolder.setLocalOnly() to convert messages to local-only (including full download) or create remote folder if needed.
reworked MessagingController.localizeUids() to fully download if necessary.
made trash folder local-only status depend on delete policy, and not able to be changed from folder settings.
fixed LocalFolder.purgeToVisibleLimit() to no longer delete local-only messages. (long-standing bug)
made processPendingAppend() (PENDING_COMMAND_APPEND) handle multiple emails and notify listeners that message has been updated.
added code to create local-only folders on settings import.
prevented user-created folder named /inbox/i.
refactored onUpload() to put all logic in MessagingController.appendMessages().
removed MessagingController.saveMessage() and reverted MessagingController.saveDraft().
automatic account setup now sets delete policy to DELETE_POLICY_ON_DELETE on IMAP accounts like manual setup does. (long-standing issue)
set default names for Archive and Spam on manual config. (long-standing issue)
added code to save/delete folder settings on new or renamed folders.
added message upload support.
added advanced option to create local-only folder.
disabled sync & push for local-only folders.
hid expunge, check_mail, and "Load up to x more" for local-only folders.
hid create/rename/delete folder options for webdav (someone give me a webdav account).
added advanced option to change if a folder is local-only or syncable.
add dialog to confirm clearing local messages, and if it should include local-only messages or just synced messages.
added advanced option to automatically upload on move from local-only to syncable.
changed background color in message list and subject color in message view of local-only messages.
changed: keep local-only messages in folders no longer on server instead of deleting folder, and mark folder as local-only.
added automatically fully downloading messages moved/copied to local-only folder.
added advanced options option (if not enabled, those settings will be hidden).
reworked onCreateFolder(), onRenameFolder(), onDeleteFolder().
added Store.isAppendCapable().
added LocalFolder.expunge() [unused].
MessagingController.updateUids(): syncs UIDs in processPendingMoveOrCopy(), instead of messages being redownloaded.
MessagingController.saveMessage(): unsynced messages can be moved, and therefore all messages are move/copy-capable.
By using the database ID we avoid having to deal with the problem of
changing UIDs. First the message has a local UID, then, when the upload
to the server is completed, it gets a remote UID.
This makes sure that when the next account is imported it will see the
account just imported. That's necessary e.g. when going though all
accounts to find the next free account number, or when avoiding account
name conflicts.
This is important for the code handling pending actions in
MessagingController. If a non-permantent MessagingException is
encountered, the pending action is retried later.
Fixes issue 3696