Merge commit 'eeaad585cd95acd5e5355ea02bb4b79715c2f9bc'
* commit 'eeaad585cd95acd5e5355ea02bb4b79715c2f9bc':
AI 147730: 1. Create an API by which a Store can specify its own custom
Merge commit 'a63e9a0c868ec2e1e50368f603e7c048140f6c81'
* commit 'a63e9a0c868ec2e1e50368f603e7c048140f6c81':
AI 147714: New, lighter-weight version of CL 147620. Still touches as many files,
Merge commit '1bca9ccac5ed54d0c90c353a3016b5559fb07535'
* commit '1bca9ccac5ed54d0c90c353a3016b5559fb07535':
AI 147620: Some stores require changing the UID of a message when it is
Merge commit 'c1a26752c1efffe17701f6795572eb9eaaa655ff'
* commit 'c1a26752c1efffe17701f6795572eb9eaaa655ff':
AI 147538: Because mPreferences is transient, we need to pass Context into the
Merge commit 'd4a1c5a232b854ff1808d6d5f8b20b06f8e25d26'
* commit 'd4a1c5a232b854ff1808d6d5f8b20b06f8e25d26':
AI 147486: Change the remote/local mapping callback to be folder-by-folder instead
Merge commit '6f25a47d4a38f04c74c0f0cc3b4fbf67edd5d3de'
* commit '6f25a47d4a38f04c74c0f0cc3b4fbf67edd5d3de':
AI 147452: Update LocalFolder.fetch() to support STRUCTURE mode, in
Merge commit '28874ce46057473eb41b9b1f6f5ee16e283444d1'
* commit '28874ce46057473eb41b9b1f6f5ee16e283444d1':
AI 147423: Provide a hook to notify remote stores that local stores are set up.
MessagingController to accept and track a Context, instead of the
unnecessary Application object, which makes this fix more testable.
BUG=1790798
Automated import of CL 147868
or other changes during a delete operation, we need to explicitly
open the remote trash folder and give it the callbacks.
BUG=1807499
Automated import of CL 147866
calls for each account. This allows the folder list to be
updated before it is synced, which is necessary for some
stores.
BUG=1807499
Automated import of CL 147839
synchronizer code.
2. Refactor (and spell-fix) the core folder synchronizer. Extract
the innards that are IMAP/POP specific, leaving common wrapper
code in a simpler shell.
3. For each account & folder to sync, check the store and call
the specialized sync'er (if provided) or the generic one.
BUG=1807499
Automated import of CL 147730
due to API change, but still has a smaller footprint. Also fixes the
bug in the original, which is that we actually needed to udpate the
local trash folder, not the remote one.
BUG=1807499
Automated import of CL 147714
*** Reason for rollback ***
We figured out a simpler solution affecting fewer files - we
don't actually need the new remotestore API.
*** Original change description ***
Some stores require changing the UID of a message when it is
copied to a new folder (I'm looking at you, EAS). Add a callback
to Folder.copyMessages() which allows the store to report back
such changes. Then, add a new api to record the new values:
Folder.updateMessages().
For now, the two APIs are linked by a common callsite in
MessagingController, so the existing stores can use a minimal
implementation - if they don't call the callback, nobody will
call the update.
BUG=1807499
Automated import of CL 147708
copied to a new folder (I'm looking at you, EAS). Add a callback
to Folder.copyMessages() which allows the store to report back
such changes. Then, add a new api to record the new values:
Folder.updateMessages().
For now, the two APIs are linked by a common callsite in
MessagingController, so the existing stores can use a minimal
implementation - if they don't call the callback, nobody will
call the update.
BUG=1807499
Automated import of CL 147620
deeper database-style operations with them. This enables two
new LocalStore APIs to be provided: A new version of
GetMessages() that can retrieve only flagged (or un-flagged)
messages, and a new method to set flags for an entire set of
messages, in a single SQL transaction.
BUG=1786939
Automated import of CL 147401
of the role-specific folders such as Drafts, Sent, or Trash.
This allows us to properly target these folders even on
systems where they have different names. I capture the
tagged names into the existing columns in the account data,
where they are used elsewhere in the code (no changes
necessary).
Use default implementations on POP3 and IMAP for now -
no change from original behavior. The new code is
primarily to support EAS (for now).
Original author: stadler
Automated import of CL 146577
The default values are 25 (default) and 25 (increment). This is fine
for Stores that control downloads by # of messages, but won't work for
stores that use other measurements - e.g. EAS windows the download in #
of days. So for this change:
1. Allow the StoreInfo to provide non-default values
2. Remove the hardcoded references to the default values
3. Use StoreInfo values everywhere
4. Set the values to 1,1 in EAS store info
Original author: stadler
Automated import of CL 146569