* Caching Senders isn't a great idea; during validation, it causes
the bug referenced below. It's a small optimization anyway, so
we'll just get rid of the cache.
* Also, remove unused code
Bug: 5144603
Change-Id: I539284dfa6d457fffd5cb011b8e1db5881249636
Always populate the contentDesription rather than only
when dispatchPopulateAccessibilityEvent() is called. Makes
life easier for testing.
Bug: 5129286
Change-Id: Ide897b81ff30708b9d637cebbf8eb63f06084a74
Creates isTesting flag in MessageListItem. When set to true,
populates the contentDescription of each message on initialization
rather than on touch.
Bug: 5129286
Change-Id: Ia0df93bf7399859a750a3fa01e5429436b9daf16
This makes "Inbox" the top level with the mailbox list one level under.
All "up"/"back" navigation is now identical and will take you upwards
towards the inbox before falling off to the launcher.
This uses a kludge and the "backstack" of the activity is not actually
represented now by the mPreviousFragment variable; it just uses tricker
in the onBackPressed()/shouldPopFromBackStack() calls to do the right
thing.
Bug: 5111629
Change-Id: Ide88efc78fe4f40d89b5ab83c480318e81902554
This eliminates the excessive padding on the left and makes the hint
text behave according to the new spec (since it uses the new action view
expanded mode).
A later CL will actually change the item to use the action view
facilities of the framework (so we don't have to manage our own custom
views).
Bug: 5109953
Change-Id: Ia3e4a1e64e65b3b8bb3e708b31636f4186acfd46
Removes done button from edit quick resposnses fragment and
centers the "create new" button.
Bug: 5111173
Change-Id: Ia847725e5d3bdc67426f76dd386f2263befe4189
This is needed so Exchange can fire up Email activities.
No change other than the move.
Bug: 5122497
Change-Id: I6ee3f61654745fafd444314ecf75eb8ae6bbd01d
There are cases when subject and snippet re null. If the MessageListItem
is not being recycled (i.e. it's the first time), this can be detected
as "no change from the previous state (of being empty)", which doesn't
initialize mText.
Bug: 5129307
Change-Id: I6df910fb365b7e8c1dd298f787d21fbb438830fd
- hide sync options for mailboxes that aren't actually syncable
- hide search icon for any mailboxes that don't have any server
counterparts
Bug: 5086134
Change-Id: I60d5e5d1225a946464c5ea273c7d4b9299f433e5
- Since the Email and Exchange processes do not share UID, we need to
ensure the call to the KeyChain to request the certificate happens in
the Exchange process
- Misc UI fixes so it's not so ugly
Bug: 5117682
Change-Id: If80698850902e0178eb0998493b4cf4b89e2a15c
- this still needs an asset for the "checkmark" button when showing
"always show pictures" prompt - using a checkbox on state as a
placeholder but it's probably not the best thing for it
Bug: 5037485
Change-Id: Iaa1d0f865bf0c01fde0b0cb37ea1c395345ed582
* Heh.
* We were using the login from the HostAuth in creating the Account
Manager account, but it should be the email address from the
Account itself; in IMAP (and usually in POP3) these are the same
* But not for juno.com!
* Updated unit test coming in another CL (tests are broken in a
strange way, and the bug is FAST-blocker)
Bug: 5110013
Change-Id: Id11799e8b30a0420804f00c2d2f265e44e39c4c0
- immediate issue was the the mIsFirstLoad flag was on the Loader
instead of the list - since the Loader is retained on rotation, we
didn't the initial list setup after rotation leaving the list in an
infinite "loading" state
- second issue was that list scroll state was being handled poorly - it
was always saved and restored needlessly. However, if two subsequent
loads happened prior to a layout, saving the list state actually saved
bad values (the restored state only seems to take effect after layout)
- third issue was the footer mode was being handled poorly as well - it
was always updated, which required re-setting the adapter every time,
which reset the scroll position. This was why we were always trying to
save/restore scroll position.
Overall this should speed up the list loading and data updates in the
list by a bunch.
Bug: 5110000
Change-Id: Id2f6db928c095ae10ee55b40e7e9241d70e0bebe
- changed activated font to white
- ensure activated bg is set even for wide (as it shows for a split
second when you select a message right before the slide animation)
- attempt to make the animation not so abrupt
Bug: 5110992
Change-Id: Ie05e0a6a09afb97155b26d28672d4a2fb79cc563
- make it take up different size on phones and tablets (also landscape
phone/portrait phone)
- move unread count outside of the spinner area
Bug: 5108972
Bug: 5111250
Change-Id: I2c16bbb52ce53bbf1c8fe08fd78f1a4b4afd4ccf
- reduces number of "modes" to just two: normal and wide
- consolidate the normal/narrow modes for phone and tablet (as per spec)
with the only diff on the tablet being side paddings
- fix issue with "white arrow" visual being shown in phone when tapping
on a message
- make touch computations be resilient to padding values instead of
assuming that the check/star icons are right at the left/right
Bug: 5103823
Change-Id: I23f967454f7744d9c59256625e302e54a353994a
* Two of the upgrades (v21->v22 and v25->v26) need to be fixed so
that they don't reference columns that might not exist.
* Oops
Bug: 4439595
Change-Id: I4a8c556be22bb85fb78807416cd1d6b81c6ef118
- updated checkboxes (new ones for sw600dp and phone)
ones for phone)
- updated stars (new ones for sw600dp and phone)
- added existing cc/bcc icon to menu item
- updated reply/replyall/forward actions to dark themed items (renames
involved)
- update message list backgrounds (new ones for hdpi,xhdpi, renamed
everything so that there is no message_ or conversation_
suffixes, also added missing states for some of the selectors)
Change-Id: I1b4f49f206b846566870f5b430e3c6386e621a0c
* While investigating the referenced bug, it was discovered that
canceling the "security required" notification (with "X", rather
than the "cancel" option in the dialog) causes the notification
to be unavailable until a reboot
* This puts the account needing a security update in the position
of being unsyncable, and might explain the referenced bug (we
have no confirmation of that step; on the other hand, the tester
can't now reproduce the problem, so an unusual action like this
is to be expected)
* The fix consists of making this particular notification "ongoing",
which prevents the user from dismissing it; arguably, this should
always have been the case anyway...
* Consider this fix for backport into LTE and MR2 branches
Bug: 5072343
Change-Id: Ia7419236cf9389380d1e079b1a9a6f425015c487
- adds a loading state to search so the user isn't left with a blank
screen for several seconds
- adds a timeout so that a warning message is shown for results that
take over 10 seconds
- use default loading/no message views in ListFragment so we don't have
to manager our own stuff
Bug: 5014107
Bug: 5037618
Change-Id: I8b03fa0967055989156c7777901affc777c4fae7
This shares the e-mail address of the currently shown account
over P2P NFC links. Note that the currently set account must
be updated actively, because the callback to create the message
comes from one of the NFC threads, which don't have permissions
to retrieve the account and the correspondig e-mail address.
Change-Id: I12e48a3787d469179e7ca074429106ed24e3a212
We seemed to not properly fallback to querying the database if the cache
did not contain a mailbox of a specific type. We may want to consider
caching mailboxes related to PIM data, but for now this is a quick fix.
Also fixes unit tests.
Bug: 5019661
Change-Id: Idcac0a6f15aa7f174890ae586f478fbb8f6e05b7
This will avoid cases where the user is permanently stuck, if we fail to
error out when a failed sync occurs or for any reason.
Bug: 5032763
Change-Id: Ib82a62add767d13dc844a90e5ea4147d3ada59dd
This info used to be shown in the top right of the status bar in GB but
that is no longer there. So before this change there was no way to tell
who you were sending as.
Bug: 5069124
Change-Id: I10d687a5fd221e65ecfc71b61cccf306492e27b8
Seems like POP envelopes could get into the database and tickle the
NotificationController even before we got the full subject/sender. Just
ignore those things until the basic info is loaded.
Bug: 5061271
Change-Id: Iadfbff8a1615d2644880f5cae3727768f4f9549a
- use title as ticker text
- also properly play notification sounds on new messages. Before, if you
left a notification unread, and a new message comes in, no sound would
be played. Since fixing that, it introduces another issue where on
initial sync, tons of new messages come in (and the sync could take > 1
min). We throttle them with a 15 second interval. The notification is
always updated to reflect the most up to date information, but sounds
will never be played closer than 15 seconds together.
Bug: 5020191
Bug: 5067059
Change-Id: I5ca474fd3b210ee856035bd78bd72931da80fe40
We were hiding the cc/bcc menu option, but on tablets that is a visible
button on the UI and not in the menu. whoops.
Bug: 5067057
Change-Id: I10ecaf115b589b9200529f6ea7703428456b8f0f
This prevents accessing a potentially closed cursor when doing batch
operations that will inevitable cause the the list to be reloaded (and
cursor to be invalidated) as the first of the messages are
touched
Bug: 5051730
Change-Id: I90328ee02eafe6ad238d8c57e88a3d96259f6547
When editing quick responses, displays an appropriate
message letting users know that there are no quick responses.
Additionally, the MessageCompose activity will only show "insert quick
responses" when at least one exists.
Bug: 4948180
Change-Id: I1191bd54d6e64f990b6d6830f0837579d7a6918c
Shortcut name is now the name of folder when it's a non-inbox
folder; otherwise it's the account name. Previously was
always account name.
Bug: 4903490
Change-Id: I15b4024d28db6a48464e423db887bdca99132423
If the account is in the process of being deleted, large parts of its
data may be being removed in parallel with notification processing. We
never handled this very well.
Bug: 5058333
Change-Id: Ic588b68438a9c5829e7e3fd5c8d52e21a037b9f4
- the container is the one that should be visible/gone - individual
fields should just be visible
- also do drive by javadoc fixes
Bug: 5052310
Change-Id: I45c4b6b7f94b2b62ac94eeff0ab97bf34c9e117a
We were hiding the search icon from the actionbar but didn't take into
account the use of a hardware button.
Bug: 5051691
Change-Id: I2e0bfd1d0bb4faa3238e567c02189894db5f6c44
This fixes a crash on account deletion, leaving around bad accounts that
were in limbo
Also remove a test for an unsupported operation
Bug: 5051951
Change-Id: Ieebc7f769075614ae1a656cf123d8ce0313e611d
On second thought, it's probably best to stick with the same account if
I can't find a particular folder. This at least is less jarring if the
user has multiple accounts.
Change-Id: Ifd5d631b220e260399681008ac17203f5451c8ff
- ensure that the commitAllowingStateLoss is actually not dangerous - we
only had one case I could see where we were actually doing a transaction
from a loader callback and I fixed that just now to not do any
transactions.
Change-Id: I21e11138f70eb2ce953a5ba54119ca46555f465d
* This CL fixes the referenced bug, but it does NOT explain how
mAccount; best guess is that the process was killed and then
restarted when the result from DPM was available.
* Assuming this is the case, we remove the background task loading
mAccount, avoiding a possible race.
* Also, it's not clear why clearNotifications didn't use the
account id argument; what if there's more than one account that
uses security? Filing a bug about this.
Bug: 5048912
Change-Id: I734834337ab6e409d77624e7c7370350de76becb
* Move AccountReconciler to the Email app (from EmailCommon)
* Ensure that Controller.deleteAccountSync() performs ALL actions
needed to clean up after an account deletion (delete attachment
files, reset policies, refresh the UI, etc.)
* Add reconcileAccounts() API to AccountService
* Remove accountDeleted() and restoreAccountsIfNeede() from the
AccountService API
* Remove unused callback
Bug: 4883073
Bug: 4767084
Change-Id: I43ffaf009db1a6f306bb0f2a74fb4dd3b2c4b966
* Not sure how this could have happened, except possibly for some
race condition
* Let's make sure it's impossible
Bug: 5032454
Change-Id: Ibd4de22dc5298fbaaf224cf4286f63bdc50aa7b9
- include settings in menu in message view
- remove "show all mailboxes" from message view
- rename "Account Settings" to "Settings"
Bug: 5039294
Change-Id: Ic2dcbe8fe6e2bd10cc5d790a74c49a7159b59cab
* This prevents the possibility of RejectedExecutionException when
selecting large numbers of items
Change-Id: I8f9ba287d69021fdb99b4a8a30cc79755f669b97
- since listContext can be null, this code was not safe.
we also filter out the search mailbox too, so it's no longer needed.
- don't ask to highlight a mailbox if doing a search
- remove a call in MailboxListFragment that was unconditionally telling
callbacks that something was selected when we started loading - this was
technically lying and if the item isn't in the list that was selected,
nothing should be called (as in the case of search). This was just an
optimization anyways and that callback is invoked later when the mailbox
list load completes.
Bug: 5037629
Change-Id: Id31c6795af9e64fa8682b67de9ab90540ee660df
Note: all unicode sending unit tests are broken due to chip issues. I've
filed a separate bug on that.
Bug: 5012204
Change-Id: I17392f65e5bd8349780b79d9cbe10492d8e7a7d9
* We waited to clear the incomplete flag until security was agreed
to, but this can lead to accounts left incomplete; we now clear
the flag as soon as the AccountManager account is created (by
convention, this is when the EmailProvider account is complete)
* Also, allow onDone() to be called more than once with a saved
account, leaving cleanly, rather than throwing a runtime
exception
Bug: 5016792
Change-Id: Ib5fc44ac045a1dd9bd5d63f922c037ed637d5341
TalkBack functions properly with MessageList items, as well as
"reply," "reply-all," and "forward" buttons while viewing messages.
It is now also possible to switch accounts using only a dpad
or trackball. Finally, EditText fields in account setup also work
with TalkBack now.
Checkmarks don't work with Talkback, but this I have confirmed and
reported it as frameworks bug.
Change-Id: I7f72682a517eef4fa122241c675026fe7997ac64
- This creates a "more" icon in portrait and shows all three actions
(reply/replyall/forward) in landscape.
- also makes the star visible by default (hiding it in EML view)
Change-Id: Iefff7c0717cfda4dc91218b0d490775294c96103
While creating or editing a quick response, disables the save
button when the edit text is empty. Also, now shows the keyboard
on the phone as soon as the dialog box pops up to edit/create
a quick response.
Bug: 5011277
Change-Id: I9926d07cae0e527a7c08a4cc556a9569a91d2f33
The default recent list should be pre-populated and fall off the list as
normal. The previous implementation showed a default list if there were
no touched mailboxes, but then the default list disappeared as soon as
there was one touched.
Bug: 5020673
Change-Id: Ifad607a9d36feff837ab42d039ce9209f223f345
Adding and removing a star triggers the appropriate accessibility
In incoming/outgoing settings, added EditText contentDescriptions.
Change-Id: Ibab461f1425b3ebf3579ebc1d0b36d1a9a5efdb2
On phones, opening "incoming settings" no longer immediately displays
the warning message associated with editing the username field. It now
only displays when the username is focused by the user.
Bug: 4282856
Change-Id: Ic0a74fa91a0f9cff66565372872e182a0eaec779
Since tablet already has to/cc/bcc labels, don't show the hint
text -- only do so when labels don't exist.
Bug: 5019806
Change-Id: I039de06e2576688e654fb0504a027cd9b9b67def
There were two issues:
- the default account ID from the provider wasn't consistent: it was
using a snapshot from the cached data but that simply returns a Map, and
the values aren't guaranteed to be sorted (and indeed I saw that the
order was different on consecutive calls!)
- hitting app up from Compose always just kicked you out to the inbox
for the default account, but it probably should have used the account of
the compose screen, since it can be specified in the Intent
Bug: 5012008
Change-Id: Ic9a753b261e047790453bc1a9417bc0c6d2f87f9
* We were deleting secured accounts when device admin is disabled,
but we were not deleting associated data, which means that
contacts, calendar, and attachment data were left on device
Bug: 5021062
Change-Id: Iabeec2dcd6ef4f52dc52e43d62803e61f7881c0d
* This fixes the case in which messages are being loaded upon
initial sync, but do NOT appear in the message list (at least
until leaving and re-entering the app/mailbox)
* The problem was that MessagesAdapter was checking the state
of the HOLDS_MAIL flag, which might not have been set at the
time the Inbox was created; it turns out that the check is
not necessary, so we remove it here
Bug: 5008696
Change-Id: I009ddf7d82d938758b99c855dfd0271596c5248a
- empty subjects should still be prepended with "Re:" and "Fwd:" when
replied/forwarded
- the compose body was being vertically centered
Bug: 5008785
Change-Id: I28e4fac8457c4fd18c764daa35d9deea1646474b
The CL I just checked in to reduce the invalidateOptionsMenu calls
removes the search icon because it expects the message list to be ready.
Instead of just invalidating the menu a bunch more, just make it so that
the icon is always shown, but we can't actually search if the message
list isn't ready. The time between the icon being shown and the list
being ready should be miniscule.
Change-Id: I5dfe9363cc904833253cf1fceeeb2af2ec389217
There were two places where account flags were being set on setup: one
was in manual setup when the user selected the account type
(pop/imap/eas), and another was when it was automatically determined
from XML. The two paths were inconsistent and one was setting bits like
SUPPORTS_SEARCH but the other wasn't.
This fixes being able to search in IMAP
Bug: 5011932
Change-Id: I50eada7485aaef4e2a85d25fa7eb9ac7ab03093a
We were unconditionally setting auth credentials even if the checkbox to
require credentials was unchecked. This prevented setup for certain
outgoing servers
Bug: 4291105
Change-Id: I27f94f02b85b097d2c6dbb896254367e8a15415b
This changes it so that the message list is shown if there are multiple
unseen messages.
Bug: 5011855
Change-Id: I14cbcfaa32cc5e2b4cb718449c62b8f39b290d4d
- Use PreferenceActivity, in the old style, meaning without PreferenceFragment.
- If setting Inbox, change the account settings instead of mailbox settings.
- Use the DialogWhenLarge theme, meaning it's a full-screen avitity on the
phone and a dialog on the tablet.
- Also fixed the bug that we the menu items that are made invisible by
UIControllerBase may be made re-visible by the 1-pane controller.
TODO The menu item shouldn't be shown for non-syncable mailboxes.
Change-Id: I02b2faf6f593e1e2eb370217c27801aa58ca7e6c
* Handle replied in new messages and updates
* Code added for upsyncing replied state, but the CL for
setting this state isn't yet submitted
Change-Id: I6f3ff56475d70f686f96ed6a84fae3468f42b1c8
The app is spending a lot of time in startup inflating XML. I suspect a
lot of it is due to the refreshActionBar() calls.
On a normal startup with NO refresh, the action bar was rebuilt 6 times.
If a refresh happens, the refresh callbacks get called in rapid
succession (20+ successive calls is not uncommon), which seemed really
wasteful.
Change-Id: I05feb56ba7fafb109d820328f591526945ca0a5f
In the common case, we don't need the "waiting for sync..." message, so
avoid inflation in those cases and just inflate on demand.
Also do a quick drive-by fix for the error message being pushed in way
too much on phones
Change-Id: Ie7a8472194659a52069d1ee21e0a0cb9b6fc91ba
Adhere to RFC2821 Sec. 4.1.3 Address Literals should be enclosed by brackets and
prefixed with 'IPv6:' if the sender is an IPv6 host
Original author: Jon Starling
Bug: 4207470
Change-Id: Id327930001188186713e38d1ce8ecc1dad8cfbc0
This is a manual cherry-pick of c379ebe372
This reverts commit 7fd14be804
The introduction of proper SD cards breaks the invariant that "external"
storage can be encrypted. Unfortunately, this means that accounts with
that policy bit set will have to be removed for now.
Accounts with the security policy set will be forced to go through
security provisioning on the next sync, using the regular mechanisms of
showing a notification with "Security update required", and then having
it fail. :(
Bug: 4466311
Change-Id: I68119b14f8d198779c2073296e228bc6772136ee
It was accidentally happening because search doesn't show the mailbox
list, but explicit > implicit.
Change-Id: Ifb8354dbb366f4c8328bef31d4e251166ae6876a