We haven't gotten all dimensions yet, but this is what I inferred from
the latest redlines.
Also fixed a margin above the message area on message view.
(Keep the margin even if there's no tabs.)
Bug 3138021
Change-Id: Iafff578f499737674ec10206b75566377cf2383b
Remove the concept of scroll speeds. According to Mark, multiple scroll speeds
is a "nice to have" feature and not a "must have". Besides, this did not work
(there was only ever one scroll speed), and, when fixed, the top scroll speed
was way too fast to be usable.
bug 3335062
Change-Id: I160bec2ca5de0b26da81ed31dfb96fc86e543988
* Remove the drag_background drawable as it is not referenced
* Correct icons for menus have been submitted; remove STOPSHIP
* Reverse target location check in MailboxListItem to fail fast if we do
not have a "down" touch event; STOPSHIP not necessary, removed
* Remove 10dip guard on mailbox list; this is near impossible to trigger
bug 3335078
bug 3335096
bug 3335065
Change-Id: I4bcc42ee03502c8a5c44d431e935dff92a648fb1
Still waiting for a few missing assets, but it's done other than that.
The divider change is already merged; new layouts all use the framework style.
It's basically all layout changes, except for:
- Now the recepient address line has "Show details", which shows a dialog with
all to/cc/bcc addresses with the timestamp.
- Now invite response buttons are checkboxes.
(But the basic behavior doesn't change -- once you check a response,
the message will be gone, so you can't change the response later.)
Copied message_header_bg from gmail manuall. It'll look silly without it.
Bug 3138021
Bug 3307021
Change-Id: I6f7eb91d6104c3143a5c58b0c4c6c19929cea477
* Stop running syncs
* Delete all EmailProvider data except the account itself (with
cleared sync key) and the account mailbox (necessary for syncing
to sync after security hold is lifted
Bug: 3245779
Bug: 3253952
Change-Id: Idc208ef5ed85808b085ebab9c26a428fb0451e34
* cleaned out old placeholders
* moved a bunch of unused strings into placeholders
* moved three strings into active status.
Bug: 3335092
Change-Id: Ibb0690f7cc9ddd1b8f7f337964faff6471be880c
Check value of ActivityManager.isRunningInTestHarness() before allowing force
account creation, instead of ActivityManager.isUserAMonkey().
Bug 3329873
Change-Id: I5028eef9caced2cacc9c187dfd746865939fdedd
If you do so, MessageCompose won't be able to restore an account, so it'll
use null account...
Bug 3324472
Change-Id: Ic0e615b31e21246e41f6f2c709a8422bef230040
Use the new icons where appropriate. This is not a complete change as there are
still some icons missing.
Change-Id: I51d1458749343ddfc6456dc2a9853b8bc2540e26
We discovered that AsyncTask.cancel() doesn't quite perform as expected;
In particular, if you call cancel() during a particularly slow background
worker, the result is discarded and onPostExecute() is never called. If
the result is an open cursor, then we "leak" by not closing it.
For AccountFolderList, which has a multi-step doInBackground():
1. Check for isCancelled() during the long doInBackground() which will
reduce the number of discarded cursors in the first place.
2. Check for isCancelled() at the end of the long doInBackground() and
if true, close the result cursors and return null.
3. In the existing isCancelled() code in onPostExecute(), close the
cursors.
For other AsyncTasks (with simpler configurations):
1. Check for isCancelled() at the end of doInBackground() and if true,
close the just-opened cursor and return null.
See also Change-Id: Ie63a3197af563baa8bb0fe6f1ef9423e281cbf4c
Bug: 3088870
Change-Id: I51b11bb5b23f209f8b61962500a063040484fd24
* Add simple sanity checks to scanned accounts, skip over if bad
* Fix existing unit tests and add new unit test for this change
* Also fixed minor bug in EmailContent that was never triggered in
production code (only discovered it via a unit test).
* Also fixed minor bug in an existing unit test
Bug: 2937595
Change-Id: Id60bbb5d8bd923db043d46891c7f89d7debb0a11
for the selected message.
This also fixes wired background flicker when you long-press.
(Apparently you can't share StateListDrawable among multiple items...)
Change-Id: I922f50a5b2a33731919e26a55bd3537d55057af5
Now it should be close enough...
Also fixed the "selected mailbox won't get hilighted" issue.
Bug 3137965
Change-Id: Ifba83783121e62363fac6428534394d2e0a4bee9
* Sending too many mailboxes to EmailProvider in a single batch can
lead to a binder exception, so we limit them
* Move all provider updates into the commit() method
Bug: 3325331
Bug: 3314442
Change-Id: I1bd8d19a96f642b6e49e2f47a5ddcebaa55c0ec0
* Update MockTransport to allow TLS connections
* Test TLS connection in ImapStore unit tests
* The bugfix: Re-query capabilities after closing/reopening parser for TLS
(Note: Actually, this is required by the IMAP RFC 3501, 6.2.1)
Bug: 3315939
Change-Id: I51f838043e87750b5712a1bd2e4f9c821b58c808
I'm not yet 100% sure what's going on, but the old code, not stopping
the scheduled forceLoad() in onReset() is apparently wrong.
onReset() is a new callback introduced in the recent loader change, so
this can explain why it started after the change.
Also, call super.onContentChanged() instead of directly calling forceLoad(),
as Loader.onContentChanged() now does more than just calling forceLoad.
Bug 3308465
Change-Id: Ica46bf994b571a26dd532734307a5c7ec6df0268
* In query of an otherwise valid URI with -1 as an id, simply return
an empty cursor
* Add unit test to verify proper handling of invalid uri's
Bug: 3183245
Bug: 3292080
Change-Id: Ia0c35cbd0f5dd0dc4a8fc794226399644cf1fe13
* DeviceAdminReceiver is actually a BroadcastReceiver, must follow
guidelines to prevent ANR or early process kill.
* Remove all uses of AsyncTask from DeviceAdminReceiver
* Pass all calls through EmailBroadcastProcessorService
* Minor restructuring of EmailBroadcastProcessorService to support
this use.
Change-Id: Ic6257ea5eff1bd466a736e0f93cb89b1cf8aa73e
* Remove unneeded DB read in onCreate (add runtime checks for problems)
* Move more exit/commit work to existing AsyncTask
* Add lockout of next & back keys while processing
Bug: 2792509 (probably others)
Change-Id: I0db030a1f1df94ba721510b5112519f260f5c0f9
* Move all db ops off UI thread
* Reorder methods in typical progression (they were random)
Bug: 3134660
Bug: 3134677
Change-Id: Idd4f411e937336bbd09bcc03d9ad036d22dc5e19
* Create sync & async versions
* Rename all callsites so sync is very apparent
* Fix callsites appropriately
* Clean up interaction between reconciler and setServicesEnabled
Bug: 3133770
Bug: 3134677
Change-Id: Iefbc7814d9aa390baea6345e450e2a4768bf0a9a
* Move each worker into async (combining common code)
* Update unit tests to match
* Make the message->account->controller lookups more efficient
Bug: 3134653
Change-Id: Icc82998a5d8eb07c7ebc7edbd28cd9308378d866
* Create shared async worker to check for duplicate accounts
* Use it in AccountSetupIncomingFragment
* Use it in AccountSetupExchangeFragment
* Debounce proceed/next button because work is now async
* Also, upgrade leftover old-style code in AccountSetupOutgoingFragment
Bug: 3134666
Change-Id: I5c24a6546d1ab66aedc5c4ac826ddf4f1ff53446
The later closes the old cursor while the former doesn't.
LoaderManager takes care of closing cursors, so no need to close
cursors by ourselves.
Change-Id: Ib652e6877dcfc1fea51ffc862254eaeed451cdfa
* Make most calls to AccountBackupRestore return immediately w/o DB access
* Move most workers in MailService into async runnables
* Remove account restore / null check from ACTION_SEND_PENDING_EMAIL
* Strengthened unit test on Mailbox.findMailboxOfType() because after
removing the account check (above), sendPendingMessages depends on
findMailboxOfType() returning -1 on a missing account.
* Clean up a bunch of warnings (no longer use deprecated Config.LOGD)
Bug: 3133763 (and probably others)
Change-Id: Id39707bca7a8ebf5000f84d542013411ff0f422e
This change is in top-level settings for a given account:
* Call saveSettings async on UI changes, instead of synch at onDestroy()
* In loadSettings, get default account id async
Also sprinkled in some TODOs for future whack-a-mole fixes.
Bug: 3133639
Change-Id: I5216c78d28b35fe47e43b48ad0db3a3e57b25004
- Don't show the progress icon unless loading from network
- Don't show the content until LoadAttachmentsTask finishes
- Disable the fade-in animation. It causes some weird positioning issue
with the GL accelerated webview.
- Use WebView.clearView() to clear its content.
- Use the "normal" layout mode, otherwise WebView won't use its entire
width
- Don't hide the vertical scrollbar
Bug 3287729
Bug 3225068
Bug 3295761
Bug 3304396
Change-Id: Ic4b8baac99b71dc0da58021849ff7c1dbd6dbe55
* Functionally correct and pixel perfect
* All current assets in place
Bug: 3292507
Bug: 3284201
Bug: 3135118
Bug: 3255036
Bug: 3252913
Change-Id: I8fa6752748c74b3a9789a3675da12f6c0c11975f
This should fix the "attempt to re-open an already-closed object" exception
from SQLite.
(destroy()s don't have @Override becuase the base method is now depricated
and will be removed someday.)
Bug 3288666
Change-Id: I4780f6c8d89c7204b266608462c0833ad5af4e5f
Sorry it is a bit ugly, it is to allow this change to be
checked in prior to the first stage of the framework change
without breaking the build.
Change-Id: I1828579019ac0325d19c070a4c62cd79549e7d51
* Copies the icon from contacts
* Used whenever the sender doesn't have a local photo
* Used in notifications and in messageview
Bug: 3282187 (notification)
Bug: 3285156 (memory leak from the placeholder graphic)
Change-Id: I528cae20355aa8cce7be37b26f32aa90e092708b
* Check content-disposition and restrict to these two types
* Add unit test
* Reformatting collectParts (code style cleanup)
Bug: 3242502
Change-Id: I5dcbdda5d4788502113771f4fd1b5fff834a402d
* onAttach is called fairly early when rotating, so it needs to do
very little.
* or in this case, defer some work until onResume
Bug: 3170922
Change-Id: Ie760125c5f32b293f8ba1753f2993de0d7439b56
- Now ProviderContextSetupHelper.getProviderContext() invalidates DB cache
* MailboxAccountLoaderTestCase
- Save hostauth properly
- (ProviderContextSetupHelper invalidates cache before each test)
Bug 3280911
* SmtpSenderUnitTests
- Use ProviderContextSetupHelper to create isolated context,
which now also invalidates DB cache
Bug 3280913
* MailboxFinderTest
- When kicking Controller.Result methods directly from tests,
call the raw callback, rather than the one wrapped with
ControllerResultUiThreadWrapper, to make it synchronous.
Bug 3280898
* MessageViewTest
- Disable testOpenMessage()
This test doesn't work because it sets up test data in an isolated
context but the activity/fragment don't see them because they
use the real context.
I have no idea why it worked before... Maybe because there were
accounts/mailbox/message with the same ID in the DB by chance.
Bug 3280905
Change-Id: I6beb08c58fff102e90bebd2c35f70820268b9e62
* Load attachments in the background for IMAP/EAS messages
* Download an attachment from account X if:
1) 25% of total storage free
2) Attachments for X use < 1/N of 25% of total storage, where N is
the number of AccountManager accounts
* Add accountKey to Attachment table for performance
Change-Id: I913aa710f34f48fcc4210ddf77393ab38323fe59
* Add the checker fragment (instead of replacing)
* Don't refresh progress/error dialogs until onResume (a bit later)
* Don't recreate terminal error dialogs that were automatically
regenerated by the fragment manager.
Bug: 3020074
Change-Id: Ia2947965b758f6846c62ac394ce51da2432523ee
- Added accountId to loadAttachmentCallback/loadMessageForViewCallback
- Cleaned up LegacyListener/MessagingListener.
Removed the constructors which take messageId and attachmentId, which
are used to bridge loadAttachmentProgress, which the callsite doesn't know
these IDs. The inconsistency (only loadAttachmentProgress() uses the member
messageId) doesn't look too good, so extracted this into a separate class,
MessageRetrievalListenerBridge.
Change-Id: I46303e50df2b0e1fe8616e7c9cef632ac14f23aa
* This was an early attempt at fragmentation
* But it turned out that no fragment was needed here - it is
not shared or reused in any way.
* Precursor to doing final layouts for the activity.
* Tested working:
Automatic provider lookup
Manual
POP/IMAP and EAS flow modes (from accounts & sync)
Force account creation intent
Provider note
Duplicate account detection
Change-Id: I434edd4b152391d36e70440873932db3ec1a1c99
* All active admin checks now go through common method
* Common code check both isAdminActive and the new (upgrade) policies
Bug: 3253179
Change-Id: Ie81f35906c164051f38c1f1f637d0c04b37eef16
A recent change was short-circuiting the logic that loads
the UI from the account. This fix simply resets the flag
so the test can reload the UI multiple times as it tests things.
Change-Id: I7cc53e2766b78172e5a7b05088e94fdec99ae0d6
1. Error banner now pushes down the entire screen, rather than covers it.
2. Switch to the new ObjectAnimator for the animation to achieve #1.
(Traditional Animation doesn't do this)
3. Dismiss the banner when getting any callback with MessagingException == null
and progress > 0, only when the account is the one that caused the last error.
4. MessageListXL now registers its own ControllerResult to detect
connection errors, and more importantly, when they're cleared.
Bug 3240874
Bug 3240406
Change-Id: I07f8e2f589bb1d312859824f9ec398879003ba16
* Add entry point via com.android.email.CREATE_ACCOUNT
* Enable when in monkey mode only
* Walks through setup screens as if auto-populated and as if
connection checking always succeeds.
* Refactored some common code in AccountSetupBasicsFragment
* Removed obsolete commentary about auto-population of EAS accts
* Also fix minor typo in FLOW_MODE_ACCOUNT_MANAGER_POP_IMAP
Bug: 2735784
Change-Id: Ie7363836cd267673e963e60ae8bc32cab422576e
* This is the fix to bug 3008626 that was created in Gingerbread
and backported to Froyo for an MR release
* The bug prevented validation of EAS w/ Exchange Server 2010 SP1
* For some reason, this fix did not get merged forward into master
resulting in the bug referenced below
Bug: 3254512
Change-Id: I4e48a8f95b31048f09a036cc16db867da4116f04
* The underlying bug was fixed by bdc in I080147b017b961502b3ba98d40841fea679491eb
This reverts commit 9166aa46da.
Change-Id: I51e7e585e7b1624cc2b08ea81baba6f2602a76cf
* For each of incoming, outgoing, exchange fragment, create a "settings
mode" which slightly alters the layout for use in AccountSettingsXL.
* Build a settings mode wrapper layout around the basic fragment
* Add new constructor to set "settings mode" and select layout
* Add wiring for cancel/next buttons in the fragment
* AccountSettingsXL configures each fragment in its settings mode
* Remove old actionbar "Next" options (no longer needed)
TODO: Pixel perfect adjustments, colors, fonts, etc.
Bug: 3188951
Change-Id: Iba26281b214333db301dd40d6c016b6c5a932c2d
This prevented EAS accounts from showing the new message notification,
because Account.newMessageCount in the cache didn't get updated
properly.
Bug 3249319
Change-Id: Id18fb94083e2f441c293414f790a26f82869e3da
* We're seeing our ping timeouts complete after 30 seconds (although
set to 5-17 minutes), due to the fact that our reused sockets are
not having their timeouts reset (i.e. they use the original value
of 30 seconds from when the socket was first created)
* Until the underlying issue is resolved, we'll avoid reusing
sockets for Ping commands
Bug: 3241899
Change-Id: I90b53c0d28b866a91507efafacbb3c4c0df2324c
* Makes things simpler for UI state on a wiped account
* Also wipe sync keys from remaining account & inbox
* Unit tests
Bug: 3245274
Bug: 3245779
Change-Id: I74cc6d7859dad54961426b70ffe0541ce49e3b91
The problem was that setIncludeQuotedText() always set mDraftNeedsSaving,
but it shouldn't be done when loading content.
(Do it only when it's toggled by the user.)
Bug 3162882
Change-Id: I6308376020f5be6d1a15b7865f8c7e02cf875eb9
* Set aggregated expiration values with DPM
* Fix min/max logic when aggregating, and fix unit test
* Add expiration tests when checking if policies are active
* Add expire-password to uses-policies set
* Handle password refresh (clear notifications and sec. holds)
* Handle password expiration (warning and/or wipe synced data)
* Unit tests for provider-level methods
* Refactor common security notification logic
* Placeholder notification strings (need final)
Bug: 3197935
Change-Id: Idf1975edd81dd7f55729156dc6b1002b7d09841f
- Set "Viewing FILENAME" as title.
- Home icon now has "back" arrow. Closes the activity when clicked.
Bug 3221312
Change-Id: I689499e10704d3c5d206df4aa12e21db9687c4c5
* New method in AttachmentProvider to delete all attachments for an
account, and unit test it.
* New method in Controller to delete all synced data for an account,
and unit test it.
* Fixed existing problem with Controller unit tests (needed cache clear)
* Fixed existing problems in Controller (mContext vs. mProviderContext)
Bug: 3197935
Change-Id: I79c6a03c21f18d37eeb8158cd1c2af0e0a6e9d2e
* Detect attachment downloads that have stalled and restart them
* Catch a couple of cases in which we weren't sending callbacks
Bug: 3122242
Change-Id: Id2bfd3b26182004b301cf8665f4feb6e62b98b73
- XLFragmentManager.selectMailbox() used to hide the message view
when it's visible, but not anymore. Made goBackToMailbox() itself
hide it instead.
- Also made onMarkAsUnread() not call the unread callback, which was
already done in onMarkMessageAsRead().
Bug 3214538
Change-Id: I52fb8bb745cdaa517624a9aeec074122f10aac4a