* Changed our queue from a TreeMap to a TreeSet that uses an easily
testable comparator
* Remove the ugly bit twiddling priority computation
* Test DownloadSet (the logic behind queue ordering, addition,
removal, query, etc.)
Change-Id: Ia8427900b8f39a243a5407349775802d0a4fad4f
* Add account is a large (+) in the action bar
* Remove account is a new item at the bottom of the settings fragment
Note: Add account works, remove account just toasts for now.
Change-Id: I5b3b8ab8c7d328cb78d103c47b9eca866466f9df
* Create AttachmentDownloadService to manage all attachment downloads
1) User requested
2) Required for email forwarding
3) Opportunistic downloads to enhance offline use
* New attachment related UI (pending UX approval, of course)
1) MessageView (attachment actions, progress bar, etc.)
2) MessageCompose (attachments for forwarded messages)
3) Associated toasts, notifications, etc.
TODO:
* Unit tests
* Cache Management (separate CL)
Change-Id: I7864a5fb1c3f4f2be68d98341a971edc6cbacfe1
- Now Welcome takes an EXTRA_DEBUG_PANE_MODE to force the
one-pane/two-pane mode.
Use this to open one-pane.
adb shell am start -a android.intent.action.MAIN \
-n com.google.android.email/com.android.email.activity.Welcome \
-e DEBUG_PANE_MODE 1
Use this to open two-pane.
adb shell am start -a android.intent.action.MAIN \
-n com.google.android.email/com.android.email.activity.Welcome \
-e DEBUG_PANE_MODE 2
Change-Id: I6e96f80f53f4488152935502c19d3dd8e0788150
* Connect to it from all call sites
* Remove 1-pane and 2-pane icons
* Leave a few more breadcrumbs for launching into specific account
* Update the long TODO list in AccountSettingsXL
Change-Id: I502eda9a622518e8d4a23d46989340ad400cdd34
Fixed the bug where callbacks for sendPendingMessagesForAllAccounts
are called on a worker threaed.
Change-Id: I28f1424cf67e15abf37c09b68050d1385f9ac3ee
It works for regular outboxes. Unfortunately it doesn't for
Combined Outbox, due to a bug in RefreshManager, which I'll fix
in a separate CL. (The fix might be rather large.)
Change-Id: Ib904e2c672801debe3dd64e4bb0a464564d098da
* Create AccountSettingsXL
* Build headers dynamically based on accounts
* Launch account settings per-account
* Temporary launch point from menu in AccountFolderList
TODO: Fragment flip to incoming/outgoing/checksettings not implemented yet
TODO: Use more recent updates to PreferenceActivity
TODO: Finish plumbing into account settings fragment
TODO: Something more real for app settings
Change-Id: I6f4c5bb8cf691f25517c25950ef2049084335ce3
Added RefreshManager, which is responsible for getting refresh requests
from UI and keeping track of what is being refreshed.
Conceptually it's a part of Controller, but extracted for easier testing.
- Now sendPendingMessagesForAllAccounts() is owned by RefreshManager
rather than Controller.
- Also updateMailboxRefreshTime/mailboxRequiresRefresh have been moved
in from the Email class.
- Now MessagingException implements a method to return an error message
for the UI.
The refresh button on 2-pane doesn't work as intended yet, because the
spec is a bit too complicated (as described in the TODO in
MessageListXLFragmentManager.onRefhres()).
This change touches many file mostly because it cleans up a lot
of code duplication.
Change-Id: I058ab745ccff10f6e574f6ec4569c84ac4a3e10e
Implemented
- The bottom buttons for MessageViwe
Delete, Mark unread, Reply, Reply all, Forward.
- Buttons for exchange invitation
View in Calender, "Yes", "No", "Maybe"
- Other MessageView events
onUrlInMessageClicked()
(Most other methods will probably be deprecated)
- Removed obsolete MailboxListFragment.Callback.onRefresh()
Fixes bug 2926517 minus "the background color of respond buttons
being black" part.
Change-Id: Ie58cbc9fde95a3e67d96846450f77ab58b175a55
- Use the class attribute instead of android:name in fragment tags.
- Use FragmentManager rather than openFragmentTransaction.
(There's a change on the PreferenceHeader tag too, but seems like we're
not using it.)
Bug 2922220
Change-Id: If604a97ac73b9ad7d84e453d36beb84bf31ff98f
doInBackground() returned a string[] when error, but onPostExecute() expects
null.
Also added isCancelled() check, just in case.
Bug 2918930
Change-Id: Ie87ff2e2e5b7c3fd77a062944759d03f8f09d3d9
Some tests create mock controllers. They register themselves to
MessagingController when instantiated, but never unregister.
Added a cleanup method, and call it for each instance.
(I was hoping it would spped up unit tests, but it didn't. Still
it's a nice thing to do.)
Change-Id: Ia90f0380aef388d22f7cfcf6e9203e05444b3285
Merge commit 'c2631344929f3befcfb3730930daa4cbaac057ba'
* commit 'c2631344929f3befcfb3730930daa4cbaac057ba':
Clear password related policies in PolicySet when p/w not required
Merge commit '9382eb9ff21855e98b67392f99d721a78a4cfab0' into gingerbread-plus-aosp
* commit '9382eb9ff21855e98b67392f99d721a78a4cfab0':
Clear password related policies in PolicySet when p/w not required
Merge commit 'a30631da1cae25be3f75137133297e30cef2db9c' into gingerbread
* commit 'a30631da1cae25be3f75137133297e30cef2db9c':
Clear password related policies in PolicySet when p/w not required
- Now MessageListFragment uses loaders to load data.
- Now that we use Loader's auto-requery with throttling,
removed the throttling timer from MessagesAdapter.
- Simplified footer mode. (now only "no footer" or "load more")
- Removed saving/restoring list state code.
These method don't really look like working, or at least
not always working. Now that UI's lifecycle is changing,
we'd better redo it from scratch.
- Removed MessageListUnitTests.
It only has tests for onSaveInstanceState/restore of the fragment,
which I virtually disabled.
And minor clean-ups
- Moved the code to save/restore selected state from the fragment
to Adapter.
Bug 2911766
Bug 2897500
Change-Id: I16c7aefecc5409c57fc5fc8c59b5c80d9b7fc164
Don't use restartLoader(). Use initLoader() with stopLoader() when necessary.
This allows us to make use of LoaderManager's "retaining" feature.
i.e. We won't have to requery when the screen orientation changes.
Also, don't start loading in onStart(). Fragment manager seems to kick
exisiting loaders after onStart(), so you'll end up getting onLoadFinished()
twice.
(Looks like I got unluck with this--there was no strong reason to start loading
in onStart rather than onResume, but I think we can leave other fragments as-is
as long as they don't use loaders.)
Seems to be working.
Change-Id: Ib4f72098bd0fcbfce284ae6e16055d20ee410cf3
Apparently IMAP servers may return multiple SEARCH responses for a
single SEARCH command, and we need to handle all of them.
Before the IMAP rework there was 3 methods that issued the SEARCH command.
Two of them ware doing it right, but the other wasn't, which was what
I copied from, unfortunately!
In case you're wondering, originally the test for this method was done through
upper methods, e.g. getMessage().
Bug 2911647
Change-Id: Ia50072944d5b01c1e59541c3a966067b13910cc4
* Apps trying to open attachments using AttachmentProvider were
seeing SecurityExceptions due to the fact that internal calls
from AttachmentProvider to EmailProvider didn't have their
calling identity saved/restored.
* Updated provider calls so that these calls use the Email
process' identity.
Bug: 2908737
Change-Id: Ifb71ad834530c6232728e1aad31439991f8ed379