For the one pane view, it's possible that an account has zero items in the
recent list (this is only possible for accounts that do not have neither
a "drafts" nor a "sent" folder). In such situations, we will still want to
have some header to distinguish between the accounts and the "show all
folders" item.
Change-Id: Ic5d6368b88ba4a28904c3b78a6489d06345a901e
When creating mailboxes (specifically 'drafts' or 'sent'), we need to ensure
that its default values for flags & server key are set correctly. In most
cases this is "okay" because the mailbox will be created on the server and
the values for these fields will be reset. However, in cases where system
mailboxes cannot be created on the sever (for example, the 'drafts' folder
on any POP3 account or an IMAP gmail account), these default values do not
get updated and we are unable to view the contents of these mailboxes.
bug 4356871
Change-Id: I9e6a394145f471b555c5827d5114bca243dbc37c
This is a stop gap fix for b/4584196
There was a race condition in which the actionbar callback happened
prior to the fragments being ready, and so any callbacks on a mailbox
would explode (and the spinner mistakenly thought the header was a
mailbox)
Change-Id: Id0a24d252472faf97088175b5c413ef554dc3b76
some imap servers will not work if the uid command contains parenthesis, while
other imap servers will not work unless the uid command contains parethesis. we
need to verify that we send both formats.
bug 4526165
Change-Id: I04a31f06a0f0fa0f03777a22b23281af574cd549
We don't need to worry about state loss here. If the fragment state is already
saved, the loader will re-fire when the fragment resumes and we'll proceed to
mailbox selection / account list as expected.
Also; only add the account selection fragment to the back stack if there is
more than one account.
bug 4558901
Change-Id: I38290fa378ac80ef5a5c8cf25c38b6e820715366
- Allow going back from the message view to the message list with restoring
all the state on the message list. (batch selection and scroll position)
- Also make "back" work for the message list <-> mailbox list navigation,
but only 1 level at most.
(Only the system back key works for this; the action bar home icon will
not.)
- As discussed offline, it uses our custum "back stack" (which can hold
at most 1 fragment) using the new fragment APIs, attach and detach.
- Removed commitFragmentTransaction() from the base class, as now there's
nothing really in common between the two UI controllers in terms of how
they use the fragment transaction.
Change-Id: Id626ce99beb1f4dceb999dc04bf7d3e5d57a8198
For the non two pane devices, we only show the recent mailbox list in the
account spinner (and not on the mailbox list fragment).
For two pane devices, we only show the recent mailbox list in the mailbox
list fragment (and not on the account spinner)
Change-Id: I1094626532ad6d6548ef441929d94546c97304a3
Some email servers require client certificates to be presented to
establish an SSL connection. While this certificate will be maintained
by the system key store, we need to store the "alias" of the certificate
stored in that system store.
Wiring up to use the actual alias will be done in future CL's. It is
currently unused.
Change-Id: I8d1290151342daea9ceb0df8a4088405b44faa81
Because isViewCreated() is used by updateSelectionMode() which is called from
onDestroyView(), we can't use getView() to determine if the CAB should be
shown.
Change-Id: I8d868998031115800766000fb0128f1d1d3541cd
Fixes two issues:
1. if a recent folder was selected from the spinner, the user could not
re-select it (even if they navigated to another mailbox using the mailbox
list) unless they manually selected another element in the spinner
2. the recent item "show all folders" did not set the associated account
position, so, when selecting that item, the spinner was not showing the
correct view.
Change-Id: I469f9f28aebd36a348534def28a4c476c0df366d
MFA was the only subclass of MA and the abstraction no longer made sense.
Collapse the two into a single adapter class.
Change-Id: I32c6f027bc37f3da08626f743c3f494e5f48c3f0
should be used.
From now on, UiUtilities.useTwoPane() should be used to see which UI
should be used.
You can pass the DEBUG_PANE_MODE extra when launching Welcome
to force which UI mode to use. (See the comment inside Welcome.)
Change-Id: Iefa3737e4979eb55f7986a9033ff9c6266d32f52
The one pane view will always have something in the recent list (either the
default recent list or the "all folders" item).
Change-Id: Ic264b59dc25504a8ce75bea6efae53a0d5dede87
- Now we "uninstall" a fragment in Fragment.onDestroyView.
i.e. a fragment transaction is actually executed.
- Maintain our own "about to be removed" fragment list to avoid
double removal of a fragment.
Change-Id: I61328e0a09a7af00cbb0e6ba10a2d39c11b5c3dc
Previously, we were deciding whether to show the spinner if the returned cursor
had more than 1 element. However, the cursor would _always_ have more than one
element because it contains a header in addition to the account information.
We now save away the number of accounts and the size of the recent list into the
cursor so we can use those counts to determine if the spinner should be shown.
Both of these counts are necessary as we want to show the spinner even if there
is only a single account as long as it has at least one recent mailbox.
Change-Id: If428c496a548a25f6b5cd7301ddb5c0d6876750c
The ability to change mailboxes using the spinner is currently only implemented
for the two-pane UI. one-pane implementation will come in a future CL.
Change-Id: If72e9d9d607508553c918f5523e748e8a481ff84