Commit Graph

4123 Commits

Author SHA1 Message Date
Andy Stadler
4b311dcdd4 Merge "Move account edit save settings off UI thread" into honeycomb 2011-01-07 13:34:41 -08:00
Andy Stadler
6e71978ec3 Move account edit save settings off UI thread
* Caught by StrictMode
* The fix prevents ANR
* Removed vestigial cruft from the saveSettingsAfterEdit() implementations

Bug: 3133633
Change-Id: Id41fb74269a2b72cc17121e33684b459d3eec869
2011-01-07 13:33:07 -08:00
Marc Blank
dc3f9f4d69 Fix widget view switching with > 1 account
* Add test case for view switching

Bug: 3329906
Change-Id: I738bad118d7d7a8d2839fbd2a9fdc00af2af3153
2011-01-07 13:20:48 -08:00
Eric Fischer
8eaa1522d9 Merge "Import some unabbreviated translations for large screens." into honeycomb 2011-01-07 12:59:34 -08:00
Makoto Onuki
1dde2253cb Merge "PPing message view: use proper text size." into honeycomb 2011-01-07 12:47:44 -08:00
Eric Fischer
fe687c8c69 Import some unabbreviated translations for large screens.
Change-Id: I7f16a7e5f2a0065496eee63a03716d17337e7222
2011-01-06 17:46:00 -08:00
Makoto Onuki
21a0c17986 PPing message view: use proper text size.
Also use the same date/time format as gmail to show the date part properly.

Bug 3138021

Change-Id: I24e45895de5330cd670a674f56eca5ccadcee9b5
2011-01-06 16:40:29 -08:00
Makoto Onuki
7523930d39 Pixel perfect: message compose
Layout & action bar icons.  Now I think it's close enough.

Bug 3138037

Change-Id: I0802f34ac23980e0faf8a0daffc016a012816d81
2011-01-06 15:01:29 -08:00
Todd Kennedy
5faff6c76a Merge "Use new holo light icons" into honeycomb 2011-01-06 13:58:18 -08:00
Todd Kennedy
64ac7a6cc8 Use new holo light icons
Use the new icons where appropriate. This is not a complete change as there are
still some icons missing.

Change-Id: I51d1458749343ddfc6456dc2a9853b8bc2540e26
2011-01-06 13:42:20 -08:00
Andy Stadler
29d79adf4b Fix cursor leaks when canceling AsyncTask
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
2011-01-06 13:35:57 -08:00
Andy Stadler
201a24f51e Harden MailService against half-created accounts
* 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
2011-01-06 12:53:40 -08:00
Marc Blank
2f1a7e8d0a Fix typo in CL 87363
Change-Id: I7a52a2a5e93dd6ccde8b040ffb7b1d224f026ce7
2011-01-05 20:35:46 -08:00
Makoto Onuki
ce9df41fc1 Merge "Pixel perfect: mailbox list" 2011-01-05 17:40:51 -08:00
Makoto Onuki
33d7399d8d Merge "action bar: make current mailbox closer to gmail" 2011-01-05 17:37:45 -08:00
Marc Blank
2b3ac66f9f Merge "Move onStartCommand processing to worker thread" 2011-01-05 17:36:55 -08:00
Marc Blank
08065b2669 Merge "Limit user mailboxes for EAS (to 1000, for now)" 2011-01-05 17:35:36 -08:00
Makoto Onuki
e9818160e1 action bar: make current mailbox closer to gmail
Still not pp, but the current one looks too ugly.  Let's change it.

Bug 3137891

Change-Id: I2e036d23b2ec99bb63fe300a5c2ade72b192f81a
2011-01-05 17:29:48 -08:00
Makoto Onuki
0187c3e203 Merge "Message list item: Use "activated" background" 2011-01-05 16:42:03 -08:00
Makoto Onuki
eaf748e6ee Message list item: Use "activated" background
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
2011-01-05 16:38:19 -08:00
Makoto Onuki
f72c4c2c2a Merge "Fix NPE in loadAttachmentCallback" 2011-01-05 16:03:56 -08:00
Makoto Onuki
80a98fd939 Pixel perfect: mailbox list
Now it should be close enough...

Also fixed the "selected mailbox won't get hilighted" issue.

Bug 3137965

Change-Id: Ifba83783121e62363fac6428534394d2e0a4bee9
2011-01-05 15:33:31 -08:00
Marc Blank
c56b246f8f Limit user mailboxes for EAS (to 1000, for now)
* 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
2011-01-05 15:29:50 -08:00
Andy Stadler
0bd7ab96aa Merge "Prevent duplicate mailbox creation" 2011-01-05 14:28:12 -08:00
Marc Blank
6f2c724f2f Move onStartCommand processing to worker thread
* Also, reduce service logging

Bug: 3133763
Change-Id: Icc09ddb5966b78350b4485e52a3d8e1f92d9c576
2011-01-05 14:21:13 -08:00
Andy Stadler
900021dbee Prevent duplicate mailbox creation
* Synchronized findOrCreateMailboxOfType

Bug: 3291982
Change-Id: I7146458112296aa2b0f4b8f24d0c86f16a8b6626
2011-01-05 14:11:44 -08:00
Marc Blank
12247faa91 Merge "Add final backgrounds to message list items" 2011-01-05 11:46:53 -08:00
Marc Blank
bd9b2ff2b3 Add final backgrounds to message list items
Bug: 3137994
Change-Id: Ife96b23815999290fc1d263ca6d8f4cedaef1b20
2011-01-05 11:46:16 -08:00
Andy Stadler
a7255de196 am 91853f33: (-s ours) am 8c45186b: Merge "DO NOT MERGE Fix cursor leaks when canceling AsyncTask" into gingerbread
* commit '91853f336044eb9a835e0f2fb4c5eea934d907c9':
  DO NOT MERGE Fix cursor leaks when canceling AsyncTask
2011-01-05 08:12:19 -08:00
Andy Stadler
f252d5d95e am 42749c91: am 1a791e67: Fix NPE when switching IMAP into TLS
* commit '42749c9105c663e035a0863d7a6bda111b5c7112':
  Fix NPE when switching IMAP into TLS
2011-01-05 08:10:26 -08:00
Andy Stadler
91853f3360 am 8c45186b: Merge "DO NOT MERGE Fix cursor leaks when canceling AsyncTask" into gingerbread
* commit '8c45186b4783cb32794d764c0f34eba90e8793ff':
  DO NOT MERGE Fix cursor leaks when canceling AsyncTask
2011-01-05 08:05:54 -08:00
Andy Stadler
42749c9105 am 1a791e67: Fix NPE when switching IMAP into TLS
* commit '1a791e675ba5092569125bf09a9fcc721bd4c5e1':
  Fix NPE when switching IMAP into TLS
2011-01-05 08:04:08 -08:00
Andy Stadler
8c45186b47 Merge "DO NOT MERGE Fix cursor leaks when canceling AsyncTask" into gingerbread 2011-01-05 08:01:37 -08:00
Andy Stadler
1a791e675b Fix NPE when switching IMAP into TLS
* 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
2011-01-04 20:21:15 -08:00
Andy Stadler
d23c361ff1 am 62ee3f4c: (-s ours) am ec988c2f: DO NOT MERGE Added/updated Yahoo provider settings
* commit '62ee3f4cac15e94dccb7795334c0355aa0e80228':
  DO NOT MERGE Added/updated Yahoo provider settings
2011-01-04 18:37:44 -08:00
Andy Stadler
62ee3f4cac am ec988c2f: DO NOT MERGE Added/updated Yahoo provider settings
* commit 'ec988c2fba0ea58e1130f24ab26aef986cb1cc4a':
  DO NOT MERGE Added/updated Yahoo provider settings
2011-01-04 18:35:44 -08:00
Andy Stadler
d2911c3e86 DO NOT MERGE Fix cursor leaks when canceling AsyncTask
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 Activities (with simpler configurations):
1.  Check for isCancelled() at the end of doInBackground() and if true,
    close the just-opened cursor and return null.

Bug: 3088870
Change-Id: Ie63a3197af563baa8bb0fe6f1ef9423e281cbf4c
2011-01-04 18:17:32 -08:00
Andy Stadler
ec988c2fba DO NOT MERGE Added/updated Yahoo provider settings
Specifically, added configuration settings for international Yahoo
domains (e.g. yahoo.ca, yahoo.de, yahoo.fr, etc), including partially
or wholly owned Yahoo subsidiaries; as well as partner domains from AT&T,
British Telecom, and Rogers whose email services are managed by Yahoo.

For domains supporting IMAP, changed to IMAP+SSL for mail handling to
support a better user experience on mobile devices.

Bug: 3258944
Original Author: Kristopher Giesing
Original CL: If5bdc70f70820f3f8aada6d2ee9b0cdb115432b5

Change-Id: Ib117f3755ff9250746f05debd1a6d1cda44c7855
2011-01-04 17:19:19 -08:00
Makoto Onuki
38a495fed9 Merge "Attempt to fix StaleDataException" 2011-01-04 16:38:05 -08:00
Makoto Onuki
1144e6c93f Fix NPE in loadAttachmentCallback
bug 3317175

Change-Id: Ib892af0b1bf00cd99c370e114dd8d98b6887933c
2011-01-04 16:28:50 -08:00
Makoto Onuki
d4cd717e9d Merge "Hide refresh button on combined view" 2011-01-04 14:55:20 -08:00
Makoto Onuki
dc1ac99210 Hide refresh button on combined view
Bug 3317656

Change-Id: I63f6fcd0aae29f01e40780bd7f69294e629aa888
2011-01-04 14:06:31 -08:00
Makoto Onuki
e447bea49b Attempt to fix StaleDataException
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
2011-01-04 13:43:07 -08:00
Marc Blank
99de346ed3 Merge "Handle query with an id of -1 more gracefully" 2011-01-04 11:17:42 -08:00
Andy Stadler
8b5cd2beff Remove UI thread access in AccountSetupBasics
* Move getOwnerName to a FutureTask
* Use AsyncTask for call to Utility.findExistingAccount()

Change-Id: I85e35a12cc28b1dda8a0ccd930869316032a3b12
2011-01-03 23:07:25 -08:00
Marc Blank
e6027c46f7 More correct fix for EAS message list callback issue (3251757)
Bug: 3251757

Change-Id: I879a97e343e9522c7c11e10a1bdd3915fc6dbaac
2010-12-31 12:48:35 -08:00
Marc Blank
cbdd9f78b2 Distinguish mailbox requests that are user requested
Bug: 3251757
Change-Id: Ie417ebf44c8b740db88e5854077782930359a958
2010-12-31 11:02:03 -08:00
Marc Blank
e70c2e0543 Merge "Fix format/draw issues with snippets" 2010-12-31 10:50:23 -08:00
Marc Blank
d306ba3438 Handle query with an id of -1 more gracefully
* 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
2010-12-30 15:02:43 -08:00
Marc Blank
3d91924c99 Fix format/draw issues with snippets
Bug: 3315171
Change-Id: I8e44c1d64d2f3382fd1e03b35e3e59b048eca31d
2010-12-30 10:22:47 -08:00