Commit Graph

904 Commits

Author SHA1 Message Date
Andrew Stadler
c41c47fa07 Enable message upload
* Create logic to detect upsyncable messages in Sent
* Note:  Drafts is now local only for IMAP - no sync, either way
* Rewrite MessageController.processPendingAppend for Provider world
* Write provider message -> legacy message converter
* Fixed bug in IMAP APPEND (it was not picking the right UID for the
    uploaded message.)
* Better handling of server internaldate
* Add constants for new X-Android-Body-Quoted-Part header
* Add EmailContent routines to get each of the 5 parts of the body
* Remove "Load more" from unsynced message lists
* Add toString to MimeHeader for debug support

Bug # 2097471

TODO (next CL): Upload attachments records too

Change-Id: I209182f5adc6b6696919f559e3cbbdd58b3eed3a
2009-09-25 14:54:32 -07:00
Mihai Preda
1086473056 MessageView: fix prev/next navigation in compound mailboxes.
Bug 2132262.

Change-Id: Ic3b8d9ccedc6101abb90dcac3545f87cbf233659
2009-09-25 11:44:57 -07:00
Android (Google) Code Review
c946f87839 Merge change 26815 into eclair
* changes:
  UI refresh and add default sender indicator
2009-09-25 14:28:24 -04:00
Marc Blank
10a4908369 Remove "Refresh" from bottom of EAS message lists
* It's confusing and inappropriate

Change-Id: I4633d34ad022ab7970384f14182dbf3c9aa4207f
2009-09-25 11:25:00 -07:00
satok
a4e604a9bb UI refresh and add default sender indicator
BUG: 1904417

* Fix the color of Read/Unread
* Add default sender indicator
2009-09-26 03:18:33 +09:00
Android (Google) Code Review
d32d78634c Merge change 26812 into eclair
* changes:
  Remember the list positions in MessageListView for onResume
2009-09-25 13:50:03 -04:00
Android (Google) Code Review
bce49bb3f5 Merge change 27048 into eclair
* changes:
  Harden a few calls in Controller
2009-09-25 13:32:45 -04:00
Android (Google) Code Review
e06706987a Merge change 27056 into eclair
* changes:
  Add check in SyncManager before stopping thread (fixes #2131380)
2009-09-25 13:18:03 -04:00
Marc Blank
484e137691 Add check in SyncManager before stopping thread (fixes #2131380)
Change-Id: I0f0dcc9721094ed29fd241b8a71e30ee0717cdfb
2009-09-25 10:16:29 -07:00
Android (Google) Code Review
0d6e69ce8a Merge change 26913 into eclair
* changes:
  Don't drop local mailboxes if we created them.
2009-09-25 13:15:00 -04:00
Andrew Stadler
e959645070 Don't drop local mailboxes if we created them.
Reimplement a dropped snippet from the original MessagingController
that preserved locally-created special mailboxes (drafts, sent, etc.)
instead of dropping them when they were not found on the server.

Bug # 2078209
2009-09-25 10:13:12 -07:00
Marc Blank
e892f6f978 Harden a few calls in Controller
* Check for null account (situation in which the Account has been
  deleted)

Change-Id: Iabd949c32443c7496a249ac5b7cdca22fc920a18
2009-09-25 09:24:56 -07:00
Android (Google) Code Review
af30d6cfac Merge change 26964 into eclair
* changes:
  Run sync threads in background priority (helps with #2126515)
2009-09-25 12:23:16 -04:00
satok
58a28fdceb Remember the list positions in MessageListView for onResume
BUG: 2131474
2009-09-25 21:22:27 +09:00
Mihai Preda
1033fe606c MessageCompose: correctly handle saving Draft in relation to restarting the activity on configuration change.
Avoids saving multiple drafts when opening/closing the keyboard.
Bug 2133003.
2009-09-25 12:29:36 +02:00
Marc Blank
7822aec383 Run sync threads in background priority (helps with #2126515)
* Seems to improve UI responsiveness while doing large syncs,
  but it can still slow down quite a bit

Change-Id: I539b8a9a96a922d810fba02ff4093759489a8153
2009-09-24 17:22:51 -07:00
Mihai Preda
7a59191bf1 Fix loading the quoted text when editing draft.
Bug 2140036.

Only load the reply fields for an edit-draft situation.

Change-Id: I851e3851ab595a0a2e6829a3bf3845ae576f1ba7
2009-09-24 12:12:56 -07:00
Marc Blank
e1145d1739 In EAS flow mode, don't try to use auto-setup (fixes #2143583)
Change-Id: I53a287d909fdde3c6ab75087a4a049c3afe9852c
2009-09-24 11:58:11 -07:00
Mihai Preda
d66b465776 Fix loading the quoted text when editing draft.
Bug 2140036.

Only load the reply fields for an edit-draft situation.
2009-09-24 15:04:03 +02:00
Mihai Preda
0dbc15e6f1 Email: catch RuntimeException when loading message with huge body from DB.
Bug: 2133062.
2009-09-24 11:58:16 +02:00
Android (Google) Code Review
4bd5034c55 Merge change 26605 into eclair
* changes:
  Add High/Low DPI assets
2009-09-24 00:25:22 -04:00
Marc Blank
b19bc4c0b6 Save HostAuth's when returning from editing Incoming/Outgoing settings
* in onActivityResult, we not only need to update the Account, but also
  the relevant HostAuth (both if coming from AccountSetupExchange)

Change-Id: I0657ff257fe949e46e100eb3e6cfec6162514aa9
2009-09-23 18:31:16 -07:00
Marc Blank
cf19af4c74 Add more ping logging to detect odd looping behavior in Moto log
Change-Id: I66f9789cf9ded590ec96b502c2f74f5d0ae5d17d
2009-09-23 17:49:47 -07:00
Marc Blank
5fed934083 Make sure we call setServicesEnabled in the BootReceiver
* Otherwise, there's a chance that various activities will be
  disabled (like MessageCompose), even if there are existing
  accounts.
* Enable BootReceiver by default

Change-Id: Id4669c41a846545d8bac5ad85736e1508074864a
2009-09-23 15:31:46 -07:00
Marc Blank
3e1c871f04 Fix EAS sending, which was inadvertently broken by a change in EmailProvider
* syncServerId in the Message table can now be NULL; this broke a test
  used by EasOutboxService and SyncManager to determine whether there
  were sendable messages in the Outbox
* Changed test to allow for NULL in syncServerId

Change-Id: Id76c7a45bc306abe7a927ab2395700f54a01a298
2009-09-23 10:52:00 -07:00
Android (Google) Code Review
8cb81390ce Merge change 26601 into eclair
* changes:
  Add a backgroud drawabled for fasttrack presence.
2009-09-23 13:07:47 -04:00
satok
35b0e2a328 Add High/Low DPI assets
BUG: 2125345
2009-09-24 02:01:33 +09:00
Android (Google) Code Review
f4a045a58f Merge change 25957 into eclair
* changes:
  Always show combined inbox
2009-09-23 12:42:30 -04:00
satok
da35b1f187 Add a backgroud drawabled for fasttrack presence.
BUG: 2053500
2009-09-24 01:41:09 +09:00
satok
fea3de19bf Always show combined inbox
BUG: 2129902
2009-09-24 00:56:41 +09:00
Marc Blank
5fc57eccef Fix reply/forward for both SMTP and EAS; fixes #2138725
* Add new introText column in the Body database
* Reply/Forward put the appropriate String into this new column
* Rfc822Output uses this when required when streaming the message

Change-Id: I34602fdb3f91692c46fc8bc31ba0e6f680d445a0
2009-09-23 07:31:01 -07:00
Andrew Stadler
0d00889f83 Cleanup Provider Message in preparation for upload
* Remove mServerIntId and its special logic
* Add mServerTimeStamp
* Add column dynamically so we don't lose accounts

Bug # 2097471
2009-09-22 18:31:10 -07:00
Marc Blank
39ec429862 Have SyncManager.ping check that the service is properly started
* If not, it will start the service
* This will catch cases in which the Email process has been killed
  while alarms are set (this would be the vast majority of the time)
* Will look into ways of catching any remaining cases...
* Fixes #2131432

Change-Id: Id71e68d14b5d1b0402c866db49a07c7b1adf499d
2009-09-22 13:22:16 -07:00
Marc Blank
4cf3252fb0 Workaround system peculiarity to fix #2134509
* Our AccountManager listener was getting unregistered due to the way
  ApplicationContext caches AccountManager in a static member
* The result was that AccountManager registers its listeners against the
  FIRST context it is instantiated with!  Future calls will all obtain
  this pre-initialized AccountManager.
* In this case, AccountSetupOptions was the first caller (to create the
  AccountManager Account for Exchange)
* The subsequent call to register a listener therefore had its registration
  tied to the context of AccountSetupOptions, and was therefore leaked
  when AccountSetupOptions finished!
* This caused a chain of problems - the leaked receiver, an Exception in
  AccountManager when trying to ping the listener in an expired context,
  and eventually the bug referenced above, which became a P1 issue

Change-Id: I478e28d21ca77419afa8011e4ed8101cdf67ab79
2009-09-22 10:40:46 -07:00
Android (Google) Code Review
b2f71dac39 Merge change 26262 into eclair
* changes:
  Only handle mailbox alarms for EAS mailboxes
2009-09-21 19:50:54 -04:00
Marc Blank
ac028f3cca Only handle mailbox alarms for EAS mailboxes
* Fixes #2135238 in which a change to a POP/IMAP mailbox
  ended up causing a sync of that box as an EAS mailbox
* The fix is to check that mailboxes with changes actually
  belong to an EAS account before trying to sync them

Change-Id: I832095ce61665813cbcfb2aa58e45a48db8a34e7
2009-09-21 16:20:26 -07:00
Andrew Stadler
fa52e6c956 Clean out old mailbox names logic and fix a couple of bugs.
* Get rid of old Account.getxxxFolderName() calls.
* Clean up any call sites to them
* Properly rename the existing special folder name identifiers
* Use a hash table in MessagingController to improve identification
    of special folders for IMAP accounts
* Fix a bug in Controller, which was creating new server-side folders
    using localized names.
* Fix a bunch of code in Controller that was using mContext, instead of
    using mProviderContext to support testability.
* Fix broken unit tests in ControllerProviderOpsTests

Fixes bug 1904373
2009-09-21 14:44:30 -07:00
Android (Google) Code Review
71bba443f2 Merge change 26224 into eclair
* changes:
  Fix broken test after changes to Rfc822Output
2009-09-21 16:16:51 -04:00
Marc Blank
e470332456 Fix broken test after changes to Rfc822Output
Change-Id: Ibb1ab79cf2cce1e5ad66d3a45656e575dbabbc6d
2009-09-21 13:16:16 -07:00
Andrew Stadler
ad4ec0590d Fix broken MessageView tests
I'm surprised these were working at all.
2009-09-21 12:59:25 -07:00
Marc Blank
f20fa620d2 On service calls to startSync, make sure SyncManager is running
* Check that SyncManager's thread is running when called for startSync;
  if not, start the service via Intent
* Mostly fixes #2133115 (although there are possibly other cases for
  SyncManager not running, this will cause any manual "Refresh" to start
  it up.)
* Added large comment at onCreate to explain how all this works

Change-Id: Ib43211ddb36e2f79ee5b1f6973f8bc2bc499024c
2009-09-21 11:31:29 -07:00
Android (Google) Code Review
06261b704e Merge change 26062 into eclair
* changes:
  make EAS set CALLER_IS_SYNCADAPTER for writes
2009-09-21 14:00:02 -04:00
Marc Blank
7b79163aac Show "sync contacts" setting properly in the settings page
Change-Id: I9c198e7795a8f2ea348361092eae22c8ff22a1a0
2009-09-21 10:39:10 -07:00
Android (Google) Code Review
c06b6290c7 Merge change 26118 into eclair
* changes:
  Clean up recent submission per stadler
2009-09-21 10:20:13 -04:00
Marc Blank
2b4b5e2f26 Clean up recent submission per stadler
Change-Id: I9fdaf3ccefe7eab41ad853e120af36b78a30ce7b
2009-09-20 22:24:08 -07:00
Marc Blank
1d4d1b8d90 Make sure we don't start account sync without push/ping active
* Wait for mailboxes to finish the initial sync while waiting in pingLoop

Change-Id: Ie1606e225261e071981cef0aab3bd623a360fc86
2009-09-20 22:18:19 -07:00
Android (Google) Code Review
c190de8369 Merge change 26015 into eclair
* changes:
  Handle issues in SmartReply/SmartForward
2009-09-21 01:04:51 -04:00
Andrew Stadler
8067b54294 UI cleanups for new account creation
* Improve appearance of basics screen and use simplified text
* Provide alternate text when in EAS account setup flow (from acct mgr)
* Change "Exchange/ActiveSync" button to "Exchange account"
* Add some spacing to the three buttons, to improve appearance

Bugs addressed:
2128055 Change string in account picker activity to Exchange
2132713 Welcome message for Email app is inappropriate when coming from
          Settings -> Accounts & sync -> New account
2009-09-20 17:26:43 -07:00
Andrew Stadler
22722207f5 Close security hole in Email provider
* Prevent open access to sent or received messages
* Prevent open access to account info incl. passwords
* Allow access only to system apps

Bug # 2133080
2009-09-20 17:23:59 -07:00
Fred Quintana
db08876316 make EAS set CALLER_IS_SYNCADAPTER for writes 2009-09-20 16:04:13 -07:00