Commit Graph

719 Commits

Author SHA1 Message Date
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
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
f4a045a58f Merge change 25957 into eclair
* changes:
  Always show combined inbox
2009-09-23 12:42:30 -04: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
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
Fred Quintana
db08876316 make EAS set CALLER_IS_SYNCADAPTER for writes 2009-09-20 16:04:13 -07:00
Marc Blank
2f99314326 Handle issues in SmartReply/SmartForward
* SmartReply doesn't put in header information related to the original, which
  looks like a bug in EAS, so we add our own (as we do for SMTP)
* SmartForward works properly, but doesn't put any CRLF between the new text
  and the original; we fix that by adding one after the original text.
* Addresses #2132658

Change-Id: I48efec0d02598a8e9ce2a54b4c66464e8e62e5d6
2009-09-20 15:50:31 -07:00
Marc Blank
cc15a77b28 Replace commented out call to actionNotifyNewMessages
* Fixes #2132978

Change-Id: Ia7d50c6eb890a5f4938ac2d567183b25e0b923bd
2009-09-20 15:19:49 -07:00
Marc Blank
7041dc5d1b Reconnect Settings -> Accounts to Email account settings screen
* This was broken during the AccountManager naming reversion

Change-Id: Ib2ccc9ca187ffdaf4a978c3c8111808be50d1583
2009-09-20 14:56:02 -07:00
Marc Blank
a740e29357 Fix bugs related to orientation change in MessageCompose
* Save reference to LoadMessageTask and cancel it in onDestroy
* Check whether we've already processed the source message
  before calling processSourceMessage
* Fixes #2097361 (Duplicate addresses in reply/reply all)
* Fixes NPE (not in Buganizer) related to fast orientation changes
  due to duplicated background task

Change-Id: Ib8115e29c9d88db1be009df4f549f925db8a1c19
2009-09-20 13:03:44 -07:00
Andrew Stadler
8d5004a6eb Modernize the code to load message and body from DB.
* Don't use unneeded managed cursors
* Put more of the DB work in async
* Don't try to load HTML and plaintext simultaneously
* Explicitly catch & handle exceptions during db ops

Bug # 2087051  (see also bug # 2122960 re unexpected db exceptions)

Change-Id: I446086bc4f3a85b2e766b12d1f7271e61e3ae8d5
2009-09-20 10:06:08 -07:00
Marc Blank
8587aa6121 Make EmailProvider more threadsafe w/r/t transactions
* Since transactions can be nested, get rid of pointless/dangerous
  flag for indicating we're in a transaction.
* Fixes #2131847

Change-Id: I2955e8a7659533e8ee9e71b949a042570466df45
2009-09-19 22:24:52 -07:00
Marc Blank
9d43de5d12 Remove parser logging from standard SD logging
* Change description for one of the logging labels to reflect
  what it actually does

Change-Id: Ib07b7330a20af5b099b42ae3733b71641c4bddd9
2009-09-19 22:19:28 -07:00
Android (Google) Code Review
726d22b962 Merge change 25895 into eclair
* changes:
  Fix service behavior w/r/t onStartCommand, onCreate, onDestroy
2009-09-19 23:41:35 -04:00
Android (Google) Code Review
02df29b647 Merge change 25903 into eclair
* changes:
  Fix bug that caused Cc field to be displayed when empty.
2009-09-19 16:52:28 -04:00
Marc Blank
a4482e865d Fix service behavior w/r/t onStartCommand, onCreate, onDestroy
* Make sure to null out vars in onDestroy
* Use START_STICKY as return value for onStartCommand
* Start SyncManager from EasAuthenticator callback, rather from the
  authenticator itself (otherwise, the Account might not have been
  created when we start SyncManager)

Change-Id: I54ff8d5586e96f016b365587717710dee3202da8
2009-09-19 13:38:59 -07:00
Android (Google) Code Review
24bbde3747 Merge change 25897 into eclair
* changes:
  Revert change to AccountManager naming; use email address again
2009-09-19 13:18:52 -04:00
Andrew Stadler
b4626d151c Fix bug that caused Cc field to be displayed when empty.
The IMAP & POP messages are being stored with cc="" instead of null,
which is taken care of by testing the output of toFriendly() instead
of the raw field from the DB.

Change-Id: I9460e7ae098ac5cd0ccd527381ffd4e6d9defae4
2009-09-18 22:54:30 -07:00
Marc Blank
657de3bfd6 Revert change to AccountManager naming; use email address again
* Forces wipe of existing accounts

Change-Id: I65d08e07a2d74f94f9142e85791d9bf49c100241
2009-09-18 20:48:43 -07:00
Andrew Stadler
9312faea43 Restore lost connection error UI
We lost the reporting of connection errors in the UI.  These were
originally displayed in FolderMessageList, under the name of each folder.

In the new implementation, we borrow the "undo" banner from Gmail and
display it whenever there is a connection error in a mailbox.

* Add banner, and code to animate it on/off the top of the list.
* Toggle banner whenever a connection state change occurs in MessageList
* Toggle banner whenever a connection state change occurs in MailboxList
* Slight change to callback semantics for sendMailCallback
2009-09-18 15:31:37 -07:00
Andrew Stadler
cd1e207200 Fix NPE when entering account settings. 2009-09-18 15:13:12 -07:00
Marc Blank
91f12b8d52 Fix problem with account settings not being saved (#2131153)
Change-Id: I6845604c6f3326e136060cace55fc53fcca867c9
2009-09-18 12:39:42 -07:00
Marc Blank
eadb55b04e Implement hooks from Settings->Accounts to Exchange account setu
* Fixes #2106718
* Fixes #2106733
* Remove "Add another account" from the preference screen

Change-Id: I8db1400d2bdb6ed7d3aeb2049cc1a399c47c38c5
2009-09-18 09:19:41 -07:00
Android (Google) Code Review
a96c941d9f Merge change 25721 into eclair
* changes:
  Clean up transport encryption & port options
2009-09-18 12:04:31 -04:00
Jeff Sharkey
68b620cca0 Switch Email to new FastTrack API.
As part of http://b/2087222 we have a new API specifically
for launching FastTrack.  This allows SHOW_OR_CREATE to be
returned to its original behavior.

I've tested this change and confirmed that it's WAI, and
may have also fixed up some deprecated references.
2009-09-17 23:59:32 -07:00
Andrew Stadler
8b91975fa5 Clean up transport encryption & port options
* Remove SSL-Optional and TLS-Optional choices from UI
* Remove SSL-Optional and TLS-Optional choices from providers.xml
* Switch over most SMTP connections from 25 to 587
* Clean up the providers list which has a lot of "optional" cases
    that were probably falling back to unencrypted.

Fixes bugs:
2110243	Settings UI shouldn't offer SSL/TLS (if available) options
2089070 Update list of providers

Change-Id: I57be57b349eed33a5284121d904528279a36a91c
2009-09-17 23:47:00 -07:00
Andrew Stadler
27bc39399e Turn off debugging code that was accidentally left on.
This goes with Change I52e53c4b.

Change-Id: Ife5672af1c0c5cf2b2c279a9a912beb26c64390d
2009-09-17 21:15:17 -07:00
Android (Google) Code Review
a6888d7448 Merge change 25459 into eclair
* changes:
  Fix sort order of MailboxList
2009-09-18 00:06:56 -04:00
Android (Google) Code Review
925be3bf76 Merge change 25462 into eclair
* changes:
  UI Refuresh of account folder list
2009-09-17 22:35:29 -04:00
satok
15206a12e8 UI Refuresh of account folder list
BUG: 1904417

* Extend chip
* Add separator between a folder button and account name
2009-09-18 11:33:30 +09:00
Android (Google) Code Review
fcdebb69a5 Merge change 25677 into eclair
* changes:
  Revert very bad commit (strange merge problem)?
2009-09-17 22:01:40 -04:00
Marc Blank
4a72c2e726 Revert very bad commit (strange merge problem)?
* This reverts commit 3f224e7efe.
* Use StructuredName.DISPLAY_NAME for Email display name on upload

Change-Id: Ic11713773d0e5b0db452dce3c9c31680ca45dbf5
2009-09-17 18:58:08 -07:00
Andrew Stadler
01f61ef912 Fix acct settings -> inbox checks -> notifications
This cleans up a number of bugs that could be generically described as
"MailService and Notifications not being updated when accounts or account
settings are changed."

This also fixes a number of race conditions, one of which was causing
accounts to be refreshed in a nearly-endless loop, and another which
could cause an endless loop of alarms to be posted & fired..

Specific changes:
* Update/reschedule any time an account is edited (this was accidentally
    broken and being handled on EAS only.)
* Make sure we reschedule if an account becomes unavailable
* Clear notifications whenever refreshing accounts
* Reload local copy of account settings whenever refreshing accounts
* When restoring prev sync times (this happens when process is killed),
    be sure to also recalculate next sync times.
* Set flags on the pending intents to make sure old pending intents are
    not being reused.
* Set a watchdog each time we check the mail, so if we are killed during
    the mail check, we will be woken up again to retry.
* Fix a 2nd race condition in which a just-created account fails to sync,
    due to not (yet) having an inbox.
* Clean up handling of Controller callback:
  * Fix a minor bug in which refresh of non-inbox mailboxes would delay
      the next timed sync of the inbox for that account.
  * If the checkmail ended in an error (result != null) the service was
      never rescheduled.

Bugs Fixed:
bug 2078149 - Update service and notifications when account settings
   change or accounts are added/deleted.
bug 2084412 - Fix race condition caused by first intent being refired
bug 2071484 - Make sure we wake up later if killed during mail check

Change-Id: I3ee0d1b389c652351de5eb798c32a2daea244067
2009-09-17 18:35:43 -07:00
Marc Blank
7e89834cfd Fix problem w/ SmartReply & SmartForward in Exchange 2003
* It doesn't like URLEncoded commands; go figure!
* Fixes #2127892

Change-Id: Ibae8cad990ed45accb6699716fda56f45c850939
2009-09-17 15:50:52 -07:00
Marc Blank
0d1f7add7d Add logging to EasOutboxService to help find sending issues
Change-Id: I8188fd2977724ae4ee6a8703098b7068c14b92fd
2009-09-17 15:20:00 -07:00
Marc Blank
b9213876f6 Fix issue with older messages not getting deleted properly from device
Change-Id: I3c3a7b6c7c6983cad47826543f9ac4291c6b2a69
2009-09-17 14:19:44 -07:00
Marc Blank
3f224e7efe Use StructuredName.DISPLAY_NAME for Email display name on new contacts
* Fixes #2115514

Change-Id: Ib9c437a1cbcbcf1069692e8d5d17d29e80369418
2009-09-17 10:14:12 -07:00
Android (Google) Code Review
492e8498e7 Merge change 25427 into eclair
* changes:
  Don't add backslash if there already is one; fixes #2124974
2009-09-17 13:07:59 -04:00
Marc Blank
e7e1ca432e Change AccountManager username for Exchange to the user's login credential
* This is not a backward-compatible change (sorry)
* Existing AccountManager EAS accounts and contacts are deleted
* Existing EmailProvider data is deleted
* Change works with new code (stadler) to avoid account duplication

Change-Id: Ife09c51fa714d91054d017b497bce603add5375a
2009-09-17 10:06:27 -07:00
satok
3449b3184c Fix sort order of MailboxList
BUG: 2083746
2009-09-17 17:33:19 +09:00
Marc Blank
c022839861 Implement HOME/WORK phones as multiple typed rows
Change-Id: I7e1c885e7735022026df9599babd48f5dbf71af9
2009-09-16 19:57:19 -07:00
Marc Blank
acfd155c12 Don't add backslash if there already is one; fixes #2124974
Change-Id: If5fa8369ee4c52449047d5134f3bf28feb88de1a
2009-09-16 18:55:28 -07:00
Android (Google) Code Review
767ea86398 Merge change 25344 into eclair
* changes:
  Add "Sync Contacts" to Account preferences screen (part of #2106733)
2009-09-16 19:11:28 -04:00
Marc Blank
e428f94161 Add "Sync Contacts" to Account preferences screen (part of #2106733)
* Also added some checks for null Accounts and HostAuth

Change-Id: Ia4ae68d0e8a62abdaf002519766b6685b6947e9e
2009-09-16 16:07:27 -07:00
Android (Google) Code Review
b734bfc08b Merge change 25320 into eclair
* changes:
  Fix NumberFormatException in POP3 message sync
2009-09-16 17:54:03 -04:00
Android (Google) Code Review
ec11b9658b Merge change 25348 into eclair
* changes:
  Fix "reloadFolderList" service call in SyncManager
2009-09-16 17:28:31 -04:00
Marc Blank
5ebdc0efeb Fix "reloadFolderList" service call in SyncManager
* Fixes #2118439

Change-Id: Iee75c5902940fb7f38f19717306708809fa06dd5
2009-09-16 14:27:39 -07:00
Andrew Stadler
092d35c98d Fix NumberFormatException in POP3 message sync
* Write unit test to replicate failure(s) in POP3 use of parseInt.  All
    calls to parseInt must be guarded by try/catch NumberFormatException.
* Fix the failures

Bug # 2115586
2009-09-16 12:20:38 -07:00
Andrew Stadler
0c4dc85190 Harden against crashes caused by account deletes
The basic failure mode is to delete an account while it is being
synced or some other background activity.  The fixes in this CL will
harden against this, but it will not be a perfect solution; That
will require shutting down all sync, which is difficult in the current
too-many-threads implementation.

Primary bug# 2112564
2009-09-16 10:58:54 -07:00
Android (Google) Code Review
fc7dfddf19 Merge change 25130 into eclair
* changes:
  Support StructuredName.DISPLAY_NAME for Exchange contacts
2009-09-15 23:12:24 -04:00
Android (Google) Code Review
2aa3e92fe3 Merge change 25041 into eclair
* changes:
  show message list selection
2009-09-15 21:56:59 -04:00
satok
5569ec9c9d show message list selection
BUG: 2117057

* add styles for items in MessageListView
* reduce color diff of Read/Unread
2009-09-16 10:55:28 +09:00
Marc Blank
ac37c5c15a Change Exchange username validation to exclude bare backslash
* Fixes #2121422

Change-Id: Id55dfa365b83d725926e3e7dcd7b646256863aa1
2009-09-15 18:05:16 -07:00
Andrew Stadler
da8836a76c Give warnings if dupe account created:
* Check for existing accounts with matching servername + username
* Show a dialog and block account creation
* Triggers in three cases:
  * After input of an auto-setup account (e.g. Gmail or AOL)
  * After input of manual setup (incoming) parameters
  * After changing incoming parameters of *any* existing account
* Made some notes in EmailContent regarding fields in HostAuth that we
    are not actually using.
* Added HostAuth unit tests

Primarily fixes bug # 1964449
Bonus fix for bug # 1594408

Change-Id: I49310faf6654280582e0ab3d3e40f2701bfcd21d
2009-09-15 16:33:44 -07:00
Android (Google) Code Review
f2147b1834 Merge change 25159 into eclair
* changes:
  Fix EAS sending (#2122221)
2009-09-15 19:23:40 -04:00
Marc Blank
a84a0e9a0d Fix EAS sending (#2122221)
Change-Id: I92ea4b1a77d96bf7992ea34026a2c5d30f33c317
2009-09-15 16:20:34 -07:00
Marc Blank
2d5691cac1 Support bcc in Exchange (Fixes #2117849)
* Must send the bcc header for EAS

Change-Id: I38d119beed334c6bb23a09b87375804f8c03ea76
2009-09-15 15:18:46 -07:00
Marc Blank
71177c5375 Support StructuredName.DISPLAY_NAME for Exchange contacts
* Fixes #2115514

Change-Id: Iac348c4ecac3bf8f895c32fff7077bc36d385bc9
2009-09-15 14:34:03 -07:00
Marc Blank
ffc681a4da Handle the case of no body being present (happens in unit tests)
* Fixes #2121403
2009-09-15 13:08:55 -07:00
Android (Google) Code Review
3bef610196 Merge change 24991 into eclair
* changes:
  change to use the new CALLER_IS_SYNCADAPTER flag
2009-09-15 15:26:50 -04:00
satok
d2174733b1 Auto-sync of stale mailboxes
BUG: 2050116
- auto sync onResume
- add mNonPushMode
-- mNonPushMode is updated in SetFooterTask
2009-09-15 14:38:13 +09:00
Android (Google) Code Review
043dba5e1b Merge change 24672 into eclair
* changes:
  Enable long press Open on Accounts screen
2009-09-15 00:42:21 -04:00
Fred Quintana
977cd2f58a change to use the new CALLER_IS_SYNCADAPTER flag 2009-09-14 17:37:18 -07:00
Marc Blank
1d98989222 Implement SmartReply/SmartForward for EAS; fixes #2098779
* SmartForward and SmartReply are EAS commands that automatically
  include the original message and, if a forward, all original
  attachments, regardless of whether they've been downloaded to
  the device
* Both commands improve battery life by sending less data; greatly
  so for SmartForward if there are attachments

Change-Id: I12432cd5275a3b54e9a80d5cd59da437c4a086cc
2009-09-14 15:47:38 -07:00
Marc Blank
42c130dcf1 Fix bug in which EAS mail won't ever get sent (#2118279)
Change-Id: Iedd80269bafd39a3536527ebe8902b4999eff41e
2009-09-14 11:03:18 -07:00
Marc Blank
e59c8725c5 Make sure SyncManager keeps running in various edge cases
* Have Welcome start the service (in case the app has been reloaded)
* Have SyncManager.ping start the service if there's no instance of
  SyncManager

Change-Id: I8bed2843a3e065d2db29fad67dfb0bb3a5d0ff5e
2009-09-14 08:50:50 -07:00
Android (Google) Code Review
d609094182 Merge change 24849 into eclair
* changes:
  Improve the checkMailbox loop query to get only the appropriate boxes
2009-09-14 10:06:44 -04:00
Android (Google) Code Review
bba6d443f5 Merge change 24858 into eclair
* changes:
  Don't wait longer than 10s for ping boxes to be ready
2009-09-14 01:53:36 -04:00
Marc Blank
4f9d5cf8f8 Don't wait longer than 10s for ping boxes to be ready
* Do a short ping in this case, which at least will allow the device
  to sleep while waiting
* Addresses #2116749

Change-Id: I9e70feaeef1361e1d66652dc66b92f6ee14751bf
2009-09-13 22:52:36 -07:00
Android (Google) Code Review
403a45e736 Merge change 24844 into eclair
* changes:
  Reimplement reply/forward to use mTextReply/mHtmlReply
2009-09-14 01:32:10 -04:00
Marc Blank
f2dded3a2f Reimplement reply/forward to use mTextReply/mHtmlReply
* Move creation of final reply/forward text (i.e. new text plus
  the original) to Rfc822Output, where it belongs.
* Prepares the way for use of SmartForward/SmartReply in
  Exchange and replying w/ multipart/alternative in SMTP
* Moved test from MessageCompose to new Rfc822OutputTests, and note
  that new tests should be added (this is not a regression; there
  were never enough tests here)

Change-Id: Ibefb842f47cc9223714856d99b8d4f55b55f49e3
2009-09-13 22:28:38 -07:00
Marc Blank
60c7502b67 Change exchange setup screen per #2025029
Change-Id: Ib94713857902e336984b847f70c96e04826b9b74
2009-09-13 21:55:10 -07:00
Marc Blank
c7897acf56 Fix NPE when adding note rows to Contacts
Change-Id: I51574db9abc45b55f8a7c19d493fdc47bc24b11b
2009-09-13 12:04:59 -07:00
Marc Blank
fa1ad355a1 Improve the checkMailbox loop query to get only the appropriate boxes
* Boxes must 1) be from an EAS account and 2) have a syncInterval that
  is not "never"

Change-Id: I5efbdc527063b2ee3373bc763b625eadfed67c4a
2009-09-13 12:04:06 -07:00
Marc Blank
f50c6d1faf Don't sync "trash" folder in Exchange
Change-Id: I6a1dc2a8ae5936bb7428d82e48ddbf114500051a
2009-09-12 16:47:07 -07:00
Android (Google) Code Review
492228bdc4 Merge change 24815 into eclair
* changes:
  Don't sync if the "Sync Contacts" checkbox isn't set
2009-09-12 14:51:28 -04:00
Android (Google) Code Review
95bc6a6ad9 Merge change 24755 into eclair
* changes:
  Allow download of contact w/ no name; don't accept empty note
2009-09-11 21:42:21 -04:00
Marc Blank
9679d4cf64 Don't sync if the "Sync Contacts" checkbox isn't set
Change-Id: I606f6c384fa34283ccee1eeaac90123347846f28
2009-09-11 18:34:06 -07:00
Marc Blank
e13ff84df7 Fix leaked intent receiver by using onStartCommand in SyncManager
Change-Id: I914c597aede6904a11a5d3119b3f7097e65b2fba
2009-09-11 16:52:07 -07:00
Marc Blank
3a0fb3b14e Allow download of contact w/ no name; don't accept empty note
Change-Id: I90058ee6c92853a3765138ca433abd7f62b60c0a
2009-09-11 13:50:45 -07:00
Android (Google) Code Review
2bab07c71e Merge change 24722 into eclair
* changes:
  Fix connection failure retry behavior; don't try syncing w/o connectivity
2009-09-11 16:09:43 -04:00
Marc Blank
a918672f4c Fix connection failure retry behavior; don't try syncing w/o connectivity
* Also remove some logging and correct some erroneous logging
* Fix the backoff behavior on IOException

Change-Id: I5fb5a0bf73eaa681eb7b9c305c838e78e7ba88ab
2009-09-11 12:59:35 -07:00
Marc Blank
3c7f0d4c00 Make exchange contact category names visible; also their members
Change-Id: Icaf7c2828db4fda7323b3ec3a6c9cd783ae80c9a
2009-09-11 08:56:34 -07:00
Marc Blank
86ada729c2 Check for null data before writing contact rows to server
Change-Id: Ib7016c43b2655e1753680c511f30cad8f4a1acce
2009-09-11 07:56:03 -07:00
satok
9486e1c1d3 Enable long press Open on Accounts screen
BUG: 2083565

Fix the button name
2009-09-11 17:59:16 +09:00
Andrew Stadler
be60dfdee7 Update MessageListView to fit punchcut's design
BUG:1904421

* update READ/UNREAD indications
** don't change color chip
** change background color
* Change Date
* Change the position of attachement icon
* Change menu icon for folder
2009-09-10 17:27:21 -07:00
Andrew Stadler
f9ab857a55 Implement delete-from-trash
* Edit Controller.deleteMessage() to handle both cases
* Refactored to start from processPendingActionsSynchronous() and
    dispatch to series of smaller methods to handle deletes vs. updates
    and the details of the various specific operations.
* Added processPendingDeletesSynchronous() which looks for delete-from-
    trash and does the right thing locally and/or remotely.

Fixes bug # 1811026
2009-09-10 16:03:34 -07:00
Android (Google) Code Review
6c6d7e3a26 Merge change 24601 into eclair
* changes:
  Fix sync-crashing bug in exchange contact groups
2009-09-10 18:55:20 -04:00
Marc Blank
058df979c8 Fix sync-crashing bug in exchange contact groups
Change-Id: I40335dcbba9653778d8376b26ae9c2455c34d0ee
2009-09-10 15:53:37 -07:00
Andrew Stadler
6c21942ec4 Implement move-to-trash for IMAP and POP3.
* Define new message-loaded state "FLAG_LOADED_DELETED" (used only for
   POP3, which needs to write sentinel messages that are not displayed.)
* Also renamed the other flags to make the naming more consistent.
* Tweak MessageList query generation to inhibit display of deleted
    message sentinels, and MessagingController won't try to resync them.
* Clean up implementation of Controller.deleteMessage()
* Add support for move to trash to MessagingController.  This operates
    in three primary modes:
  * POP3 local delete (no server-side interaction)
  * POP3 server delete
  * IMAP server delete (and copy to IMAP trash mailbox)
* Add missing implementation in provider to delete all of the attachments
    for a given message
* Fix progress reporting in activities (the test for error vs. progress
    was inverted, which caused progress indicators to keep spinning
    after errors.)
* Fix broken account settings UI (POP3 delete policy was not persisting)

Addresses bug 2097409

TODO delete from trash / empty trash

Change-Id: I00188e6dc2093823106e009f35b68c760227c9e6
2009-09-10 12:44:05 -07:00
Marc Blank
c522cfa770 Change ping loop wait from 10s to 1s to reduce WakeLock use
* There is a better way of implementing this, which I'll write up in
  Buganizer, but this will help our battery life testing

Change-Id: I2583f0cb9c62b38aee64166138385d7b14855832
2009-09-10 12:26:26 -07:00
Marc Blank
ffe998914d Remove temporary code that disabled contacts upsync
Change-Id: I41273aeac3059a49a1fffc7904e580a8544724bf
2009-09-09 22:38:05 -07:00
Marc Blank
805562e26f Fix logic for use of "Sync Contacts" button value
Change-Id: I9abed1830a61795542bdf15ee62395a63abc9222
2009-09-09 18:37:42 -07:00
Android (Google) Code Review
d46ec14e6e Merge change 23483 into eclair
* changes:
  Rework ContactsSyncAdapter to handle untyped Email and IM data
2009-09-09 18:49:54 -04:00
Marc Blank
6d1271aee7 Fix crash in large tests (#2108431)
Change-Id: I82a0ec81361b722bfa1cb4f197e3c999936ff192
2009-09-09 11:14:48 -07:00
Marc Blank
009fd35e92 Rework ContactsSyncAdapter to handle untyped Email and IM data
* This is required to due a change in ContactsProvider2 that removes
  type information for these fields

Change-Id: I993aebdcace0e1db538a85afdea3389fe41518d8
2009-09-09 11:08:35 -07:00
Marc Blank
cef2344e70 Rework EAS account creation & ssl operation
* Fixes 2048663, 2025029, and 2100131
* Add "Trust Certificates" checkbox in EAS account creation
* Use custom ClientConnectionManager for HttpClient with registry
  for plain, ssl, and tssl (trusted ssl) connection
* Use a ConnectionPool for HttpClient connections
* Remove "Domain" checkbox in  EAS account creation
* Remove tests related to the "Domain" field
* TODO Write a test for valid usernames (requires a bit of research)
  <name>, <email address>, <domain>/<name, and <domain>\<name> are all
  valid, but there might be others

Change-Id: I4a0338df5960bfd3d679a88aaf22d1c49f49992b
2009-09-09 10:32:06 -07:00
Marc Blank
e256983193 Add sourceKey to Body table; add flags for reply/forward in Message
* Set reply/forward flag and sourceKey as appropriate in MessageCompose
* Update provider tests accordingly

Change-Id: I7f49d80a735314a1a38f09fbf1f234257c41af8c
2009-09-08 16:42:53 -07:00
Dmitri Plotnikov
4587efc1d3 Replacing old contacts API references with new ones. 2009-09-08 14:34:20 -07:00
Android (Google) Code Review
e8a37cf769 Merge change 24088 into eclair
* changes:
  Re-enabling email suggestions and switching to new contacts API.
2009-09-08 13:22:24 -07:00
Dmitri Plotnikov
a5b855898d Re-enabling email suggestions and switching to new contacts API. 2009-09-06 11:50:35 -07:00
Android (Google) Code Review
c688b085d0 Merge change 24069 into eclair
* changes:
  Have SyncManager stopSelf if there are no EAS accounts
2009-09-06 10:46:49 -07:00
Marc Blank
6e7ea8cfe6 Fix problem with case of attachment name in EAS
* Fixes #2102752

Change-Id: I9cc05a8fc02344f1f673c5ccb4e6aed0f9602350
2009-09-05 22:13:55 -07:00
Andrew Stadler
7b03c7936a A bit more debugging to catch the service race condition.
NOTE: This switches on Email.DEBUG for everyone, and should be
removed.


Change-Id: I700099a9aa5e5c64d8c282cb8d07a47c7c408862
2009-09-04 23:13:32 -07:00
Android (Google) Code Review
8549068cb5 Merge change 23963 into eclair
* changes:
  MessageView: bug 2076472, fix deletion WRT prev/next navigation.
2009-09-04 23:10:02 -07:00
Marc Blank
f1f8e81628 Have SyncManager stopSelf if there are no EAS accounts
Change-Id: Icfca3a7f93a9eb382dca19b9f69c461e92eb6bd8
2009-09-04 22:20:37 -07:00
Marc Blank
b8d0c55a05 Fix reply all behavior to prevent duplicates, etc.
* Also create a bogus account if none exists to prevent setup failure
* Fixes #2087413 (Email large tests failing with Unknown URI)
* Fixes #2097361 (Duplicate email address when replying...)

Change-Id: I9ca2ac5f98db43e9009c22421c69956440356e34
2009-09-04 20:39:02 -07:00
Andrew Stadler
db003dd489 MessageView: bug 2076472, fix deletion WRT prev/next navigation.
- fix doPrevious() which was not correctly moving the cursor due to
    bug 2100645
- correctly handle configuration change (keyboard open/close) by saving
    the current message
- reorder the operations in onDelete: first move the cursor, and next
    delete, to avoid the possibility of the observer call happening with
    the deleted message as messageId.
2009-09-04 17:24:26 -07:00
Android (Google) Code Review
5d09beeacb Merge change 23803 into eclair
* changes:
  MessageCompose: Bug 2078435, Correctly set the attachement flag.
2009-09-04 17:03:17 -07:00
Marc Blank
9be10e62ed Remove the "unique" requirement for serverId; it should never have been there
* People using multiple accounts without this change could end up with missing folders
* Fixes 2099514
* Database version incremented; this change will cause a database wipe

Change-Id: I08d23fa54d8194758e1f7c2ffb528a14bc184f08
2009-09-04 16:36:39 -07:00
Android (Google) Code Review
5768ef614b Merge change 23939 into eclair
* changes:
  Fix crash related to long press of footer view in MessageList (2099784)
2009-09-04 16:15:48 -07:00
Mihai Preda
3113ae67fd MessageCompose: Bug 2078435, Correctly set the attachement flag.
- display "saved as draft" toast for save draft.
- don't display tost for send.
- don't cancel the sender task, let it complete.
- synchronize on mDraft although not sure that it's needed.
2009-09-04 18:14:27 +02:00
Mihai Preda
62fb7cf5f5 Email MessageView: Bug 2053500, presence.
- fix the query for presence status.
- put it in an AsyncTask instead of Thread, remove from Handler.
- set the target rect when invoking the presence bar.
2009-09-04 11:14:15 +02:00
Marc Blank
8af8523154 Fix crash related to long press of footer view in MessageList (2099784)
Change-Id: I4be240096022ee69244532bbf876a47a520188bc
2009-09-03 22:56:06 -07:00
Andrew Stadler
9b9a2e69b9 Improve logging in MailService
The goal is to generate better reports to help find the race condition
described in bug 2084412

Change-Id: Idfc453af17edf08e89d2aa656585b83ed48691c8
2009-09-03 15:02:03 -07:00
Mihai Preda
4f11b50de5 MessageView: Bug 2097855, observer on prevNextCursor unregistered twice. 2009-09-03 15:27:55 +02:00
Android (Google) Code Review
67650c8bf7 Merge change 23435 into eclair
* changes:
  Email: BUG 1964940 Support multiple share from Gallery in Email
2009-09-03 01:37:26 -07:00
Android (Google) Code Review
bc1e760c11 Merge change 23771 into eclair
* changes:
  Fixed Labels for buld email
2009-09-02 21:42:43 -07:00
satok
58bd29e740 Fixed Labels for buld email
BUG:2084730
2009-09-03 13:34:31 +09:00
Android (Google) Code Review
9c60b110a9 Merge change 23726 into eclair
* changes:
  Clean up next/prev behavior in MessageView
2009-09-02 21:09:35 -07:00
Android (Google) Code Review
7c4a39981d Merge change 23657 into eclair
* changes:
  Fix the foldername of outbox
2009-09-02 17:51:17 -07:00
satok
4bb52e36b1 Fix the foldername of outbox
BUG: 2077596

* fixed the array of special_mailbox_display_names
* added unit tests
2009-09-03 09:47:00 +09:00
Andrew Stadler
6d22ccaa2f Clean up next/prev behavior in MessageView
To improve functionality of next/prev buttons:
* Stop using managed query for next/prev cursor, so requery won't
    run in UI thread.  Add explicit lifecycle management.
* Requery on every onResume()
* Use a listener to catch external changes.  This applies both to synced
    changes and also local deletes.
* If we ever find ourselves out of the list, finish() immediately
    to avoid any race conditions.

To reduce flicker & other problems during msg-to-msg navigation:
* Clear attachments list so it doesn't accrete as we navigate
* Clear body so we don't show previous body with newer headers

Fixes bug 2076472 and (possibly) 2069241 & 2078933
2009-09-02 16:49:24 -07:00
Android (Google) Code Review
d1d87b4dc9 Merge change 23709 into eclair
* changes:
  Put in temporary code to prevent contacts upsync based on Gservices setting
2009-09-02 15:47:22 -07:00
Marc Blank
65652eee27 Put in temporary code to prevent contacts upsync based on Gservices setting
Change-Id: I89ae0495da9daa85aee7e411cf159fd3c010ee13
2009-09-02 15:32:02 -07:00
satok
64814b3928 Update the design of Unread Count
BUG: 2065601

* Show Unread Count of Accounts in AccountFolderList
* Change the background according to the folder's type
* Change the style of unread counts

TODO: Change background images of Unread Count
2009-09-03 02:54:22 +09:00
Andrew Stadler
91a5cd517f Clean up handling of Exchange setup option
* Use concrete declarations, not the old sample code
* Remove unused "sample" code
* Create ExchangeSender.java
* Strip out the unused (old sample code) parts of ExchangeStore.java
* Unit test to make sure EAS is being offered
* Fix "account leak" in AccountSettingsTests

This was triggered by donut bug # 2092944 but the solution is
different because we support EAS here.
2009-09-02 09:45:28 -07:00
Mihai Preda
fa2238ca40 Email: BUG 1964940 Support multiple share from Gallery in Email 2009-09-02 15:38:48 +02:00
Andrew Stadler
936babc145 Bulk change of columns, LAST TIME.
* Add reply columns to Body
* Remove a bunch of unused columns from Message
* Update SQL tables, content read/write, etc.
* Small tweaks to app code that was not-really-using the old columns.
* Update existing unit tests for new/changed columns
* Disable TagsTests to solve a tests failure (prexisting, not caused by
    this CL)

Change-Id: Ief493796dfe219669755170d76786f91570cbb9b
2009-09-01 23:19:12 -07:00
Android (Google) Code Review
4bc201d9d0 Merge change 23405 into eclair
* changes:
  Use bulk delete for wiping contacts, now that it's implemented in ContactsProvider
2009-09-01 08:44:02 -07:00
Android (Google) Code Review
1b59056661 Merge change 23021 into eclair
* changes:
  Email: check for closed cursor in onPostExecute for AsyncTasks.
2009-09-01 04:31:26 -07:00
Marc Blank
75a0873dd9 Remove the temporary call to start SyncManager in Welcome.java
Change-Id: Ic15b19374e89d2b1329e55d4bc86336499a983fd
2009-08-31 22:06:30 -07:00
Marc Blank
7266d90dac Make mailboxes respect the sync interval of the Account
* Fixes #2089954

Change-Id: I1b632462ad23da5f024efe2d13ebb11e8e600c67
2009-08-31 21:45:58 -07:00
Marc Blank
469d07fdd4 Use bulk delete for wiping contacts, now that it's implemented in ContactsProvider
Change-Id: I0363901902cc8c17116222eb78bacd2e96ad28d7
2009-08-31 21:43:54 -07:00
Marc Blank
b3e4c79873 Change ContentObserver for Account; fix two bugs
* Fixes 2085862 and 2087385

Change-Id: I38e046e861ec0423669506194c0bcd6c9c96328c
2009-08-30 19:24:56 -07:00
Marc Blank
617720eb35 Handle user deletions in Exchange Contacts sync (i.e. upsync them)
Change-Id: I94a8d83b4739b6439a7a87c0bf22ed165a9c9186
2009-08-29 20:09:52 -07:00
Marc Blank
ebda784732 Fix bugs related to Contacts sync behavior in Exchange
* Respect the UPLOAD extra from SyncManager and check for changes before starting
  a sync.
* Failure to do this was causing looping behavior

Change-Id: Idfb1c35782b6d3771f9455c6fe86489572a871c5
2009-08-29 12:55:55 -07:00
Android (Google) Code Review
a7927a874b Merge change 23116 into eclair
* changes:
  Create BootReceiver for Exchange for proper self-management
2009-08-28 18:23:19 -07:00
Marc Blank
58267fe146 Fix some Contacts upsync bugs; add logging for serialization
Change-Id: I855a8ee3df520f53fc94866b8463d314cf800ca5
2009-08-28 16:37:29 -07:00
Marc Blank
53cb37c3ef Create BootReceiver for Exchange for proper self-management
Change-Id: I95e9e632de91d7f0e2505bf8879e1c164861f58c
2009-08-28 11:42:17 -07:00
Android (Google) Code Review
bd4fe2db84 Merge change 23114 into eclair
* changes:
  Fix upload of read state for Exchange emails
2009-08-28 10:28:21 -07:00
Marc Blank
c29ec54532 Fix Contacts sync adapter required by change to SyncManager
Change-Id: Icfc1f191289170185548a03ca94d1f79f10b7519
2009-08-28 10:25:20 -07:00
Marc Blank
85a78c7495 Fix upload of read state for Exchange emails
Change-Id: Id5959f9c2394644e88b3961dea24f54ff1ad7141
2009-08-28 10:24:27 -07:00
Android (Google) Code Review
e3a25fe58d Merge change 23009 into eclair
* changes:
  fix a bug that can allow multiple syncs to start in parallel
2009-08-27 20:02:54 -07:00
Fred Quintana
63ec89f61a fix a bug that can allow multiple syncs to start in parallel 2009-08-27 18:33:49 -07:00
Mihai Preda
285efb4aff Email: check for closed cursor in onPostExecute for AsyncTasks.
BUG 2081965
2009-08-28 02:05:31 +02:00
Android (Google) Code Review
52129ec4b2 Merge change 23001 into eclair
* changes:
  MessageCompose: BUG 2069196, compose email from the correct account.
2009-08-27 16:50:14 -07:00
Mihai Preda
948e5ae63b MessageCompose: BUG 2069196, compose email from the correct account. 2009-08-28 01:29:33 +02:00
Android (Google) Code Review
ab11649eed Merge change 22989 into eclair
* changes:
  Fix usage of isDefault and IS_DEFAULT to be consistent
2009-08-27 16:24:02 -07:00
Android (Google) Code Review
5525e2b3c1 Merge change 22996 into eclair
* changes:
  Fix NPE in bug #2080357
2009-08-27 16:23:52 -07:00
Marc Blank
242fde1920 Fix NPE in bug #2080357
Change-Id: I07c0b65e16568e9cf182b70302f2a1ce90d2581b
2009-08-27 15:58:44 -07:00
Marc Blank
0401ad5334 Fix usage of isDefault and IS_DEFAULT to be consistent
* There was inconsistent usage between int and boolean for this column

Change-Id: Ifa7bd6f2563920a95b6b714f3a7b14e5be29d176
2009-08-27 15:26:06 -07:00
Mihai Preda
0967b74a62 am 629e18ad: Fix base64 decoder. BUG 2081740.
Merge commit '629e18ad866917523599ed059898f4d986e49e26' into eclair

* commit '629e18ad866917523599ed059898f4d986e49e26':
  Fix base64 decoder. BUG 2081740.
2009-08-27 15:16:39 -07:00
Mihai Preda
629e18ad86 Fix base64 decoder. BUG 2081740.
It was broken by CL 22378.
The bug was in the situation when "==" (two padding chars) were at
the end, the reading did not stop after the first '=',
and thus one more char of output was generated.
Add more unit-test for base64 decoding.
2009-08-27 22:24:30 +02:00
Marc Blank
f8a81b94a3 Set ContactsProvider Settings so that ungrouped Exchange contacts display by default
Change-Id: Ie7ede23efdd371816c8dc190b8269abd83c5f238
2009-08-27 11:00:59 -07:00
Android (Google) Code Review
4118beebed Merge change 22654 into eclair
* changes:
  Move some Contacts fields to new CommonDataKinds rows
2009-08-27 09:17:52 -07:00
Android (Google) Code Review
6c47a98184 Merge change 22873 into eclair
* changes:
  Clean up onCreate/onDestroy methods for SyncManager
2009-08-27 09:15:57 -07:00
Android (Google) Code Review
2ded414e99 Merge change 22840 into eclair
* changes:
  Sync "read" and "favorite" back to server.
2009-08-26 23:14:28 -07:00
Andrew Stadler
423206653f Sync "read" and "favorite" back to server.
* Add \FLAGGED support to IMAP (writeback)
* Add code in Controller to kick MessagingController
* Rewrite pending commands system to scan through provider's updated
    messages table and react
* Fix a unit test that I broke
* Cleaned out some of the old PendingCommand support

Addresses the 2nd half (upsync) of bug 1904385

TODO:
Can I add a unit test for IMAP flag writer?

Change-Id: I5a96a695d4f35fca1395506f165b86d9fb19b543
2009-08-26 23:12:02 -07:00
Marc Blank
317a92f51f Clean up onCreate/onDestroy methods for SyncManager
* Put most of onDestroy code into the run method of SyncManager's thread
* Clean up code for updating Mailboxes' SyncKey and interval
* Fixes 2080472

Change-Id: Ie16c851a686142d9fd1d810a942aa786690b1034
2009-08-26 22:09:53 -07:00
Android (Google) Code Review
6c99ea3d02 Merge change 22829 into eclair
* changes:
  Fix #2081145 (Empty subject line imitates magic eight ball)
2009-08-26 16:37:56 -07:00
Marc Blank
b01bce9b50 Fix #2081145 (Empty subject line imitates magic eight ball) 2009-08-26 16:37:05 -07:00
Android (Google) Code Review
7ac828bce8 Merge change 22823 into eclair
* changes:
  Fix bug #2080302
2009-08-26 15:50:26 -07:00
Marc Blank
1851882c8c Fix bug #2080302
* Was trying to retrieve an integer as a boolean in the ContentValues
* The actual Exception (ClassCastException) was buried by ActivityThread
2009-08-26 15:38:30 -07:00
Android (Google) Code Review
58299b0b66 Merge change 22793 into eclair
* changes:
  Handle errors in account creation by AccountManager
2009-08-26 14:31:54 -07:00
Android (Google) Code Review
eac52c9398 Merge change 22798 into eclair
* changes:
  MessageCompose: bug 2080075 &  2077496.
2009-08-26 13:57:45 -07:00
Marc Blank
a3c6c6ed29 Handle errors in account creation by AccountManager
* Don't create our EmailProvider Account until we get a confirmation from
  AccountManager that the system Account is created
* Put up an erorr dialog if AccountManager fails for some reason (this is
  what we saw in bug #2072668)
2009-08-26 13:20:23 -07:00
Mihai Preda
ea0fea2558 MessageCompose: bug 2080075 & 2077496.
- fix bug 2080075, reply to message without text body.
- workaround bug 2077496 by temporarilly disabling the address adapter.
- unit test for MessageCompose.buildBodyText()
- use precompiled regex
2009-08-26 21:49:31 +02:00
Andrew Stadler
2ac94a9cc2 Update Star and Read/Unread from IMAP server
* Set the star and the read/unread states properly when a
    message is downloaded for the first time.
* Update them on already-downloaded messages.

This is download only - not upload
Bug 1904385

Change-Id: Id03a0957677bb39f4a57ed0542eaa8accc36ab48
2009-08-25 22:45:11 -07:00
satok
c1edb4a801 Show/Hide/Change appropriate buttons in footer of MessageList.
BUG: 1904403

* Change the text of READ/UNREAD button dynamically according to the state of selection
* Change the text of favorite button dynamically according to the state of selection
2009-08-26 08:38:06 +09:00
Marc Blank
04e3ba8ffd Move some Contacts fields to new CommonDataKinds rows 2009-08-25 15:00:15 -07:00
Andrew Stadler
98c10db510 Clean up menus in MessageList
* Final list of options while normal mailbox is shown
* New list of options while smart folder is shown
* Correct lists of context options for drafts, outbox, trash, and
    everywhere else (full list)
* Enable reply, reply all, and forward

TODO: needs a better icon for menu->folders

Resolves bug 1904421 items 4a, 4b, 5a
Resolves bug 2078092
2009-08-25 14:11:38 -07:00
satok
67be84728a Update UI of accounts folder list and smart folders
BUG: 1904417

* Changed the order of menu options
* Made context menu for smart folders
* Added context menu for Accounts
2009-08-26 03:42:49 +09:00
Mihai Preda
9b27c7fd90 MessageView: display inline images.
- also display "show pictures" the same as in donut.
- inline images don't show in attachemnts list.
2009-08-25 20:32:26 +02:00
Marc Blank
68c3c7518e Use LED for notification (same parameters as Gmail and GTalk services)
* Agreed to by Erick and Prasenjit

Change-Id: I1a0f3642c9b10f981b2feed55762407ed853763d
2009-08-25 11:06:17 -07:00
Andrew Stadler
df86adf873 Finish the code to demand-load partially loaded messages.
This happens in two primary cases:
1.  When a very large POP message was skipped during initial sync
2.  When any message was interrupted during initial sync, e.g. by
    a dropped connection.

Changes:
* Added loadMessageForView and callbacks to Controller (and touched all
    files with Controller listeners)
* Rewrote loadMessageForView in legacy MessagingController to work with
    provider.
* Update flow in MessageView to use loadMessageForView when needed.
* Restored the use of "loading.html" and "empty.html" assets (although
    I think we should replace them with simple layouts & views.)
* Some random cleanup in MessageView

Satisfies bug # 2065563
2009-08-25 10:13:35 -07:00
satok
60a04912e0 Change all context menus
BUG: 2051086

* Add titles to all context menus
* Fix bug that prevented display of context menus in MessageList

TODO: localize special folder names
2009-08-25 22:14:28 +09:00
satok
dadba99498 Localize special folder names
* make utility for looking up icon id for mailbox
* make utility for looking up localized name for mailbox

BUG: 2065586
2009-08-25 16:20:32 +09:00
Marc Blank
aa69a17477 Add initial support for uploading new Contacts to Exchange server
* Refactor the sync adapters to separate out parsing from commit
* Use ContactsProvider to save the SyncKey for contacts
* Fixes #2072664 and #2072456

Change-Id: I1e85c498496e83d9523489636a75f366f7fbd106
2009-08-24 18:45:14 -07:00
Marc Blank
e2e466e315 Null out reference in onDestroy method
Change-Id: Idc3b7c52ae60121756e071ed2468ee1b9496c1c1
2009-08-24 18:01:49 -07:00
Android (Google) Code Review
137be44d5c Merge change 22502 into eclair
* changes:
  Fix #2074992
2009-08-24 17:53:24 -07:00