Commit Graph

26 Commits

Author SHA1 Message Date
Tony Mantler 4aec413a1e Warnings and Finals
Change-Id: I47f29c16c066eb077c64ef8c89e91df88d15caf0
2014-04-29 11:46:22 -07:00
Anthony Lee dc6bb6aa41 b/14075613. Treat empty strings the same as null strings.
Found this issue when addressing the root problem for this bug and testing
with various mixes of text and html content in emails.

Change-Id: I875fd9fac85b07484c27db383e3ac4a3cb935ee6
2014-04-22 14:12:20 -07:00
James Lemieux 1fa303478c Eliminate redundant methods in Address class
THIS DOES NOT CHANGE ANY EXISTING FUNCTIONALITY.

Address.pack() has been removed and all calls replaced with its synonym Address.toHeader().
Address.unpack() has been renamed to Address.fromHeader() to follow the new naming convention.

In days of yore, pack() and toHeader() used to do different things. Now they are identical and
thus one is superfluous. We have standardized on toHeader() and fromHeader().

Change-Id: Iac91c966eb6c1477f8dba0dd2ae01c84b359e539
2014-01-22 16:15:57 -08:00
Alon Albert cde694c5e1 Check for ArrayIndexOutOfBoundsException
Quoted text pos may be out of bounds of message body.
This may be caused by the pos being calculated in html while the message is being
sent as plain text. A seperate CL will attempt to address the root cause. This
is a last resort so we don't crash.

Bug: 11538910
Change-Id: I326ebe56ee15368983caa2fa76605e7658dab014
2013-11-12 15:33:45 -08:00
Scott Kennedy 1b8e0fa23f Clean up a bunch of warnings
Bug: 9565838
Change-Id: I5e95562bbf463f057cbcc4a9884427a774473b45
2013-06-25 15:34:32 -07:00
Andrew Sapperstein 91973256c2 Moved code out of emailcommon to UnifedEmail.
This CL is mostly just deletion since the new code
is in a new project.

Change-Id: I4aee519187a6ed7514c97d2a7a85ed29ea29d25f
2013-05-31 16:28:51 -07:00
Yu Ping Hu 7c3f85885c Changes to support cleaving sync out of ExchangeService.
Change-Id: Idbfff4ddc8fca4829228d04816d40a4ab9639382
2013-05-15 15:04:59 -07:00
Paul Westbrook 5a3aebbd2d Fix problem with sending attachments in Exchange
The problem was that when the attachment was attempted to be opened
from the Exchange process, it didn't have access to the cached file.
Instead, use a content provider uri to reference the cached file.

Bug: 8400456

Change-Id: I80abd66642e938cf09f73bf0e9bd049aa8d7ba1d
2013-03-21 17:34:19 -07:00
Paul Westbrook 9a95253846 Cache attachments on send
Cache attachments in a email directory when sending to allow sending
to succeed when the content provider has a permission

Bug: 7381557
Change-Id: Icf9faead2048de237228625f998b42feade48978
2013-02-27 09:43:31 -08:00
Marc Blank 6e5bccf2c9 Use correct attachment provider authority
* Make sure new code works with old Attachment rows

Bug: 7130972
Change-Id: Ia5d258930f39266517eead535a92bb4380fdb594
2012-09-09 09:32:14 -07:00
Marc Blank 77d166b8d1 Allow writeTo to accept a list of attachments to send
* The default is to send all attachments, of course, but with
  smartSend, we need to exclude the original ones or they will
  be duplicated
* Another CL in Exchange is required to fix the bug

Bug: 7005505
Change-Id: I0e8bab2fb53dd4d60c82f2ef9a525ff7b015f2eb
2012-08-20 13:18:59 -07:00
Marc Blank 970fe5316b Progress updates for POP3 message downloads
* Also, handle MessagingException when doing STAT

Change-Id: I5267b64f18a84fcc97fc2d003e49d4e373ea02c5
2012-08-03 17:03:25 -07:00
Marc Blank f6db592c31 POP3 renovation
* Much, much faster
* Remove message length pass and lots of other useless code
* Create pseudo-attachment for long messages (click to download) that
  includes size (so user can determine whether it's worth it)
* Handle download of message via pseudo-attachment; real attachments
  are then created as necessary.

TODO: Add real UI with UX input (or modify existing to clean up the
loose ends)
TODO: Optimizations for loading the whole message
TODO: Get server delete working (isn't working currently anyway)

Change-Id: I31f3809fc5a2f9fd490d33cfed70d2930654e71d
2012-08-02 15:26:30 -07:00
Marc Blank f419287f22 DO NOT MERGE: Move emailcommon2 sources to emailcommon
Change-Id: I06df7e467cd2e0117df8b8db3ddc6ff9da13f1c7
2012-06-28 11:15:06 -07:00
Marc Blank 09a071a879 Don't use multipart/alternative for SmartReply/Forward text
* When confirmed fixed, this should be backported to MR2/MR2

Bug: 4490341
Change-Id: Ie99047b465ed7087e6e0100f7d517ac3fb6b803c
2011-05-26 10:19:01 -07:00
Todd Kennedy de70ee5f78 Don't duplicate HTML in reply / forward
On exchange servers that support "smart reply", the original message is
actually appended by the server. In this situation, we should not append
the original HTML text on the client.

but 4177192

Change-Id: I6fad74ac761e2abfe7cb0f536df4db30f7d5ca9a
2011-03-25 14:25:48 -07:00
Marc Blank 5604f5eebc am b50a766d: Merge "Remove STOPSHIP logging" into honeycomb-mr1
* commit 'b50a766d4acc563beff90d22dc3dac48038ff4f1':
  Remove STOPSHIP logging
2011-03-17 08:03:08 -07:00
Marc Blank da3c4b8261 Remove STOPSHIP logging
Change-Id: I73786fb2f4ff10d3c0767a873e5eb1e443f1affc
2011-03-16 11:08:56 -07:00
Todd Kennedy 8e09307b27 am 39121c75: Fix display of inline images
* commit '39121c758dcc919b5fde4c893d488916e26d3140':
  Fix display of inline images
2011-03-08 10:21:54 -08:00
Todd Kennedy 39121c758d Fix display of inline images
Inline images can be specified in two different ways -- explicitly with a
Content-Disposition of "inline" or implicitly with no Content-Disposition.
We correctly handled the former. For the later, we now default to an "inline"
disposition if one was not specified. This is acceptable per RFC 822 which
states:

     Content-Disposition is an optional header field. In its absence,
     the MUA may use whatever presentation method it deems suitable.

Additionally, if the disposition is not specified by the server, we need to
look at the Content-Type header for the file name.

bug 2824698

Change-Id: I146f7a67197b4e737e5f82a3d570e0f74e23fa35
2011-03-08 07:53:56 -08:00
Todd Kennedy d8bce7e731 DO NOT MERGE Add original HTML message to forward/reply
When replying or fowarding an HTML message, we now send both plain text and
HTML bodies as a multi-part mime message. We take special care to ensure the
message bodies are in their own multi-part block and do not interfere with
any additional attachments to the message.

bug 3060920

Backport-Of: I2fc3cb4e1f65bcc28486a62731b44b0ee0a99719

Change-Id: I89ec2795b55ceb7472a8ee3db2dc8f50cf537d9c
2011-03-03 15:27:09 -08:00
Todd Kennedy 9cc51b72c6 Attach original HTML message on forward/reply
When replying or fowarding an HTML message, we now send both plain text and
HTML bodies as a multi-part mime message. We take special care to ensure the
message bodies are in their own multi-part block and do not interfere with
any additional attachments to the message.

bug 3060920

Change-Id: I2fc3cb4e1f65bcc28486a62731b44b0ee0a99719
2011-03-03 14:37:03 -08:00
Ying Wang 37f3385803 Split out emailcommon/Android.mk
Change-Id: I846ee2a4b541f4709e647aa537c61549db2bec2e
2011-03-01 15:56:27 -08:00
Ying Wang a07f2ae0b1 Revert "Split out emailcommon/Android.mk"
This reverts commit c28bf35319.
2011-03-01 14:52:05 -08:00
Todd Kennedy 7c87bfc33a Change "appendQuotedText" to "useSmartReply" in Rfc822Output
Slight API change to make it more clear what the method parameter is for.
Also add some additonal test conditions to the Rfc822Output tests.

Reapply changes in CL https://android-git.corp.google.com/g/#change,99090

Change-Id: I7a48c9544e48cbdf44b14f4b1f8d92fe01f7861e
2011-03-01 14:46:38 -08:00
Ying Wang c28bf35319 Split out emailcommon/Android.mk
Change-Id: I90653e8601ee3ee6a8719d87ffb93222a11a22c0
2011-03-01 12:29:05 -08:00