Commit Graph

31 Commits

Author SHA1 Message Date
Tony Mantler 2f288864b6 Fetch email bodies using ContentResolver#openInputStream
This brings us further along the path to storing email bodies
outside of the database.

Change-Id: I96296114ade0d561df724878ed92999306bcd176
2014-05-08 15:50:57 -07:00
Martin Hibdon b5713fb731 am 81f9a57a: Fix some STOPSHIP logging
* commit '81f9a57a655fe842ddd86b14afe75bcd575edb81':
  Fix some STOPSHIP logging
2014-05-05 20:19:12 +00:00
Martin Hibdon 81f9a57a65 Fix some STOPSHIP logging
b/14564870

Change-Id: I9365013eacde23178578b45f728713f80417bc7a
2014-05-05 13:04:19 -07:00
Tony Mantler 3dd85723a1 Cleanup in EmailContent
Change-Id: Ifa251eb206779f59ea003f99395d454c7e407bc2
2014-04-14 12:54:39 -07:00
Martin Hibdon 8cb95732b0 Make oauth error handling localizable
Also, add some logging to track down b/13545303

Change-Id: I44a0d63b5c3b53018b48eb1c58d6a9ff74bddd9c
2014-04-03 14:28:50 -07:00
Tony Mantler 840408c41c Remove mAmAccount from the email provider account object
b/11070468

Change-Id: I51bad4be41800e4cd6dae42744005ade784cdf82
2013-10-04 10:21:25 -07:00
Scott Kennedy 26f741fbaf Remove some warnings
Change-Id: Ifc855a6c8623bd980807064477635c19b8ed81e0
2013-08-01 22:14:01 -07:00
Yu Ping Hu 2075c97f60 Delete most of IEmailServiceCallback.
The old callback mechanism is deprecated, in favor of making
calls on the ContentProvider.

Bug: 9842867

Change-Id: I65f559e593cda24456c4ffb96f785e054626dd0b
2013-07-29 20:04:42 -07:00
Scott Kennedy 560bfadc31 Unify LogTag
There is now only one LogTag class. The static initializer of
GmailApplication (existing) and EmailApplication (new) will now set
the log tag to "Gmail" and "Email", respectively. Up until that code
is run, it will be "UnifiedEmail".

"setprop log.tag.Gmail VERBOSE" (or .Email) will trigger all logs to
be printed as long as they go through LogUtils, regardless of what tag
is used by that individual log. This lets us still turn on logging
everywhere in one command, but also lets us use more descriptive tags
(like the class name).

And since we no longer have three com.android.mail.utils.LogTag
classes, builds will be much easier.

Also, we now use LogUtils everywhere.

Change-Id: I55f1c7a66ce50ead54877a13e40256422a56dc39
2013-06-05 20:06:15 -07:00
Yu Ping Hu 1484c6663d Code cleanup.
- Cleanup sync adapter to not have statics & locks.
- Remove some dead code.

Change-Id: Ia310d32b93706dc3742ccee74e5b751174280488
2013-04-30 14:21:19 -07:00
Yu Ping Hu 9e7f5a2a33 Use system SyncManager for Exchange.
Change-Id: I77e4e75c94c532d22a28cf97e6f55f1259b8bdde
2013-04-25 14:03:00 -07:00
Yu Ping Hu 7539508bfc Add a way to check whether we have a wakelock.
Bug: 8640907

Change-Id: I886af09d20dab195a9bbd38082a02d29e8b864e7
2013-04-18 13:48:57 -07:00
Marc Blank 72d7dda97d Improve service dump a bit
Change-Id: I850aebae0f8b20f0041672dc36a361c5b2d73f9a
2012-09-19 12:46:13 -07:00
Marc Blank 4639556e52 Add bugreport dump of wake lock times
Change-Id: I4086e8ee620ac10d5a3c1673838c567753c1a553
2012-09-19 11:21:14 -07:00
Marc Blank 1bcf32e1b2 Don't sync at all if 1) upsync and 2) held
Bug: 7148468

Change-Id: I93a7734f274263e09ddef1b5cf7d9d7ea58a17c3
2012-09-11 18:07:55 -07:00
Marc Blank 4417adce6d Don't clear errorMap due to upload sync
* Clearing it will prevent backoff behavior from working
  properly when there are changes to be uploaded

Change-Id: I1a1509e42730a3aa36298e3024068b6fe993e045
2012-09-10 12:45:53 -07:00
Marc Blank e714bb9d15 Convert authorities, intents, and account manager types
* Tested ok on wiped Nexus
* Tested ok on S3
* Upgrade verified on Nexus

Change-Id: If5d4ce594f8a309cdb59589d10b1d33f3b79326c
2012-08-31 23:26:36 -07:00
Marc Blank 70edcf0538 Integrate Imap2 into Email
* Also, convert imap accounts to imap2
* The original imap service remains, but is no used
* There remain some questions about how the upgrade
  should work in terms of settings

Change-Id: I0e05edad6a1553f428a2c2fa3daf1df878d4b5f7
2012-08-22 14:17:57 -07:00
Marc Blank cf566e251b Make sure that all access to service map is lock-protected
Bug: 7013731
Change-Id: I9da734d19597997b34d6079cf013064262a75ec4
2012-08-19 08:30:56 -07:00
Marc Blank 9531e5ea5f Revert "Make sure that all access to service map is lock-protected"
This reverts commit 9d593aab1b

Change-Id: I2b8f044e2119c60b9a42c7cb84577147c89ea0cb
2012-08-18 17:19:37 -07:00
Marc Blank 9d593aab1b Make sure that all access to service map is lock-protected
Bug: 7013731
Change-Id: Ib5e1f2aa92fd448f0a4131393a34d93315bfa649
2012-08-18 14:03:45 -07:00
Marc Blank bc53491b95 Ensure that security notification is posted if not active
Bug: 7007658

Change-Id: Ia422c30c47b044279471e549541ac6279735828c
2012-08-17 11:24:39 -07:00
Paul Westbrook e444155bce Fix ConcurrentModificationException
Bug: 6937046
Change-Id: I82e578d9b31b0064570deee9a9625ddf07826112
2012-08-06 10:50:00 -07:00
Marc Blank 3a83ec1cf8 Don't save connection manager for autodiscover/validation
* Also add outlook.com to providers file

Change-Id: I2c334d1307b84899c3b64bd0c3f0cd92c190576e
2012-08-01 13:51:19 -07:00
Marc Blank 7d5e2a7c08 Do "same certificate" checking when using "trust certificates"
* Refactor/simplify Transport/MailTransport
* Add serverCert column to HostAuth table in EmailProvider
* During first connection to server, save the server certificate
  in the HostAuth; on subsequent connections, ensure that the
  certificate presented has the same public key as the one
  stored
* For now, we'll just fail to connect (with a CertificateException)
  if there's a mismatch

TODO: Add some UI to handle different certificates

Bug: 6888866
Change-Id: Ia79497e89eaad8d43617b50d3771121b2ed7f687
2012-08-01 09:04:44 -07:00
Marc Blank dba0b20d95 Handle ALERT response to login command
* Allow AccountService loginFailed API to take a reason string
* Present the reason string in the dialog shown from the login
  failure notification
* Handle ALERTs in IMAP login responses (for example, some servers
  will occasionally require web login and we need to inform them,
  rather than simply saying the password is wrong)
* This fixes a longstanding bug in our Imap1 implementation

Change-Id: I8b270cd5d4746559b6c8a78bce02f0e7c525bdea
2012-07-27 13:36:41 -07:00
Marc Blank 0b6b83c6f9 Imap2 additions
* Implement first-pass Imap2 server-side search
* Improve number parsing performance
* Better handle the BodyThread (loading message bodies)

Change-Id: I0ccd7377c80a0553b086d5204b211067896a2f49
2012-07-27 11:58:48 -07:00
Marc Blank 41bba664f7 Fix EAS backoff behavior (was stuck at 30 seconds)
Bug: 6881519
Change-Id: Ib0b6f8a07a4bc47d3691c9cfa711e45eaf1955f2
2012-07-25 15:38:50 -07:00
Marc Blank 98497ec7f6 Prevent ConcurrentModificationException in SyncManager
Bug: 6856652
Change-Id: I1a264844cbab159505b4b3ebd32716a469517f0a
2012-07-23 10:17:05 -07:00
Marc Blank a8b683cf3f More work on Imap2
* Handle sending mail and moving to sent folder
* Implement picker for sent folder
* Upload sent items to server
* Add support for "automatic" sync window
* Move some files from Email -> emailcommon
* The added files are copied directly from Email (and can be
  removed if/when Imap2 is merged back with Email)

Change-Id: I3a6a3d224826e547748be2f1b567b6294ad5db89
2012-07-19 14:27:17 -07:00
Marc Blank c6089bc01f Initial Imap2 implementation
This CL includes the following:
* New Imap2.apk generation (not included in builds)
* "Push IMAP" option for accounts when Imap2.apk present
* Account creation/setup
* 2-way sync of messages, deletions, flag updates
* Push (messages, flags)
* Folder list hierarchy handling
* Message text (one plain or html part)
* Picker UI for trash folder (placeholder)
* Capabilities handling/UI command

Major Imap2 new features:
* Push
* Multiple folder sync
* Sync window (like EAS)

TODO:
* Picker UI for sent folder
* Upload of sent messages to server
* Search
* Multiple viewable parts
* Probably lots more, incl. unit tests

Change-Id: Ia5d74073d9c307e0bdae72a7f76b27140dde7d14
2012-07-18 11:32:26 -07:00