Commit Graph

323 Commits

Author SHA1 Message Date
Marc Blank
fc579d4477 Refactor, cleanup, and fix sync bugs
* Found/fixed major sync bug re: first-time sync (emulator only)
* Moved deviceId code to SyncManager
* Added code to handle some edge cases related to sync errors
2009-08-07 22:29:15 -07:00
Marc Blank
b9d6ba11c7 Fix various problems related to synchronization, reload folder list, etc.
* The reloadFolderList service call mustn't reset the account mailbox if the foler
  list has never synced
* Be careful to not commit anything after a mailbox has been stopped
* Be careful to synchronize before checking the stopped state of a mailbox
2009-08-07 12:17:23 -07:00
Marc Blank
9b598924ec Try to work around the "ping loop" problem in some Exchange 2003 servers
* First try reloading the folder list; this can sometimes work
* Otherwise, change push to 5 minute sync
* Send notification if we switch to 5 minute sync so there are no surprises
* Added syncStatus column to EmailProvider (can be used for any purpose)
* Use syncStatus to keep track of sync type, result type, and change count;
  detect ping loop as consecutive ping's with no changes
* Remove InteractiveSyncService (no longer needed)
2009-08-06 20:51:54 -07:00
Android (Google) Code Review
17d86bb529 Merge change 20277
* changes:
  Initial support for Exchange account creation via AccountManager
2009-08-06 12:51:30 -07:00
Marc Blank
06275c4207 Initial support for Exchange account creation via AccountManager
* Export AccountSetupBasics so that it can be launched by AccountManager
* Update EasAuthenticatorService to return an Intent for AccountSetupBasics
* UI needs to be updated to skip account type screen, change welcome, etc.
2009-08-06 12:50:34 -07:00
Mihai Preda
a5af05f1a9 MessageCompose: load body.
- load body for edit-draft, replay, forward.
- fix debug secret code for no-keyboard devices.
- fix CR-LF BUG 1911254.
- fix menu invoke compose from folder with mailboxId < 0.
2009-08-06 11:40:42 +02:00
Android (Google) Code Review
47f1b7a32b Merge change 20084
* changes:
  Change context menu by mailbox type See bug 1399964 for details.
2009-08-05 23:24:57 -07:00
satok
375f968aa5 Change context menu by mailbox type See bug 1399964 for details. 2009-08-06 13:52:23 +09:00
Android (Google) Code Review
6d130d6d6d Merge change 20078
* changes:
  Separate out name and address from EAS contact email fields
2009-08-05 19:57:27 -07:00
Android (Google) Code Review
d65901784a Merge change 20206
* changes:
  Fix EmailProvider so that deletions can occur during batch operations
2009-08-05 19:54:41 -07:00
Marc Blank
cba3a48f97 Fix EmailProvider so that deletions can occur during batch operations
* Fixes bug #2034170
* Attach the body database during all batch operations
* Change insert, delete, update, and query to use the main database for
  all operations during a batch operation; trying to use the body database
  while it is attached will result in a SQLiteException (database locked)
2009-08-05 19:53:20 -07:00
Android (Google) Code Review
b3ceddb1b1 Merge change 20088
* changes:
  Don't show mailboxes with flagVisible=0 See bug 1938449 for details.
2009-08-05 19:22:17 -07:00
satok
bbcb150dee Don't show mailboxes with flagVisible=0 See bug 1938449 for details. 2009-08-06 11:21:26 +09:00
Marc Blank
25c46808c6 Check existence of mWakeLock before releasing it
* Also, unregister connectivity receiver in onDestroy method
2009-08-05 13:03:06 -07:00
Marc Blank
228d422951 Separate out name and address from EAS contact email fields
* Use newly created sync adapter column for name portion
* Fix typo in note upload
2009-08-04 22:51:07 -07:00
Marc Blank
b4d87dfdd0 Add support for note and category upload for Contacts
* Also fixed a few random bugs found while debugging
2009-08-04 11:06:58 -07:00
Marc Blank
b2bd8a8095 Add support for additional EAS contact fields
* Fix a few misc. bugs found while testing
2009-08-03 17:00:05 -07:00
Marc Blank
e7e999ee95 Send OPTIONS less frequently; remove extraneous Log command 2009-08-03 10:49:10 -07:00
Mihai Preda
2917e895c7 MessageCompose:
- set displayName for composed messages (from To:)
- set FLAG_LOADED
- do the save & send in an AsyncTask
- some clean-up
2009-08-03 13:04:21 +02:00
Marc Blank
b9f5134672 Fix inadvertent submission with debug flag set 2009-08-03 00:10:49 -07:00
Marc Blank
6696c26da3 Fix bugs related to push & reloading folder list
* Fixed bug #2026451 (updateFolderList isn't interrupting pingLoop)
* Added some logging code related to 'ping' and manual service starts
* Handle exit from stopped sync thread better
* Fixed a bug in ContactsSyncAdapter service in which a cursor didn't
  get properly closed.
2009-08-02 15:35:04 -07:00
Marc Blank
f00dccd321 Massive reworking of EAS serialization; much smaller and faster now
* Remove all use of Strings in favor of the parser's static final int's
* Strings remain in Tags for debugging output only
* Renamed lots of classes to be more consistent
* Centralized logging behavior in Eas class
* Found and fixed some bugs in the process:
  - Account deletion wasn't removing HostAuth's correctly in the trigger
  - Adding a second EAS account was trashing the first one
  - Fixed looping sync behavior caused by Exchange 2003 bug
2009-08-01 17:55:15 -07:00
Marc Blank
cc8b35e631 Temporarily force updateFolderList to send start/stop callbacks to UI
* Keep this in place until the related bug is resolved
2009-07-31 11:02:17 -07:00
Andrew Stadler
77898e14e9 Enable logging in EAS based on Email.DEBUG flag. 2009-07-30 21:47:32 -07:00
Marc Blank
59b7da4616 Fix 2026451 (folder list update callback not being made)
* Make sure updateFolderList service call stops the account mailbox sync
* Make sure SyncManager is kicked so that it will restart (and thus do
  a folder list sync)
2009-07-30 21:34:48 -07:00
Andrew Stadler
8f7f93a7b3 Enable account & mailbox sync for exchange
* Now attempts folder list sync for exchange
    (goto folder list and click sync)
* Folder sync never seems to call our callback - bug in EAS side?

* Now attempts mailbox sync
    (go to an EAS mailbox and click sync)

Also:
* Cleanup start/stop/error path for IMAP/POP as well
* Small bugfix in SyncManager.java (was calling wrong callback)
* No longer trying to set mailbox read/unread count in IMAP/POP
2009-07-30 18:48:12 -07:00
Android (Google) Code Review
5dd01e89a4 Merge change 9197
* changes:
  Use providers to update the unreadCount of Mailboxes
2009-07-30 16:23:08 -07:00
Marc Blank
758a532fce Use providers to update the unreadCount of Mailboxes
* Triggers added for insert/delete/update of Message
* update of Mailbox will never set unreadCount
* Removed old test for unread counts and replaced with on
  that tests trigger operation.
* Remove Account.updateUnreadCount (deprecated)
2009-07-30 16:03:31 -07:00
Andrew Stadler
9f9aaeaa3a Updates to AccountFolderList
* Switch to custom list item view
* Make the folder button work right
* Add the "Accounts" separator
* Change top text to "Email"
2009-07-30 15:50:08 -07:00
Marc Blank
85ef72b2ce Add support for the syncMailboxStatus/syncMailboxListStatus callback
* Allows UI to show proper progress indications depending on the status
  of a particular mailbox (running, finished, or error state)
2009-07-30 14:01:09 -07:00
Andrew Stadler
90ed7a4e23 Convert AccountFolderList to flat list
TODO: convert item to custom view
TODO: click on folder icon
TODO: mailbox per-type icons (e.g. inbox, outbox)
TODO: separator between two sections
2009-07-30 10:01:01 -07:00
Marc Blank
948c36f47a Reimplement EAS contacts sync to work w/ new system facilities
* Modify to work with ContactsProvider2
* Modify to work with system AccountManager
* Modify to work with system SyncManager (for triggering user-change syncs)
* Sync server->client for adds/deletes implemented (CP2 doesn't handle delete yet)
* Sync server->client changes handled efficiently (only write changes)
* Some fields still not handled
* Rewrote most of the CPO code to handle server->client changes
* Sync client->server works for supported fields
2009-07-30 09:22:40 -07:00
Andrew Stadler
9150b3005f Convert AccountFolderList to fat title bar style.
Also sharing fat title bar layout with MailboxList now.
2009-07-29 23:18:43 -07:00
Andrew Stadler
9e5ee4589f Create MailboxList for new UI activity.
* Shows mailboxes
* Click to open mailbox (see messages)
* Basic menus
* Fat title bar (appearance)
* Fat title bar (buttons)

Temporary hack to call this from AccountFolderList (when you click the
account groups and "expand" them, you come here instead.)
2009-07-29 19:21:37 -07:00
Andrew Stadler
ea69fc40d7 Rework Controller to use new single callback from EAS.
* Use unified callback instead of per-call callbacks
* Remove per-call tag
* Rework MessageView to operate without tag
* Minor cleanups in service side
2009-07-29 18:36:01 -07:00
satok
183e4a7a85 Localize special folder name 2009-07-30 10:08:36 +09:00
Marc Blank
c449cba510 First pass at implementing new IEmailServiceCallback.
* Add setCallback method to IEmailService interface
* Remove the callback from loadAttachment and loadMore in SyncManager and
  EmailServiceProxy
* Remove the callback from PartRequest
* Update EasSyncService to use the saved callback in SyncManager

Note: Unsure how to handle the case in which SyncManager dies, since it
will no longer have the callback available...
2009-07-29 13:36:13 -07:00
Android (Google) Code Review
eeac194150 Merge change 8810
* changes:
  initial Controller.sendMessage() and invocation from MessageCompose.
2009-07-29 00:59:33 -07:00
Android (Google) Code Review
aef3fb963b Merge change 8744
* changes:
  Show/Hide Account folders dynamically by checking number of messages
2009-07-28 16:17:17 -07:00
satok
fac5dc2d77 Show/Hide Account folders dynamically by checking number of messages 2009-07-29 05:56:23 +09:00
Mihai Preda
334903369e initial Controller.sendMessage() and invocation from MessageCompose. 2009-07-28 20:48:42 +02:00
Mihai Preda
3e79032dd1 Fix MessageCompose tests.
BUG 2017612.
2009-07-28 16:27:04 +02:00
Android (Google) Code Review
67143e5680 Merge change 8646
* changes:
  Remove mOldMessage from MessageView.
2009-07-28 04:52:45 -07:00
Mihai Preda
ff683a5b98 Remove mOldMessage from MessageView.
And add Address.unpackFirst() (used in MessageView) + test.
2009-07-28 13:49:40 +02:00
Android (Google) Code Review
274576bb90 Merge change 8656
* changes:
  Load source message in UI in MessageCompose for reply/forward/edit-draft.
2009-07-28 04:47:48 -07:00
Andrew Stadler
a98de7e55e Finish Attachment support for EAS accounts.
* Change service API to allow caller to supply complete target path/file
* Also allow caller to supply the final content_uri
* In MessageView, use full integration with EAS service API and
  attachments content provider to enable:
  * Save: Only works on SD card
  * View: Works w/o SD card using content provider & intents
  * Thumbnail previews
2009-07-27 19:52:21 -07:00
Andrew Stadler
3d25a519ab Convert AttachmentProvider to use new Provider db.
* Rewrite internals to use EmailProvider instead of raw db access
  * Minor changes to APIs as necessary (and scattered changes to follow)
  * Convert unit tests and check them
2009-07-27 15:52:42 -07:00
Android (Google) Code Review
63b2ad5bfb Merge change 8633
* changes:
  Fix UnsupportedOperationException in AccountSetupBasic caused by Account.update() when !isSaved().
2009-07-27 12:46:38 -07:00
Mihai Preda
0712ce063c Load source message in UI in MessageCompose for reply/forward/edit-draft.
Replace EmailContent.Message with Message.
Remove MessageCompose.mAccountId (mAccount is enough).
2009-07-27 21:22:37 +02:00
Mihai Preda
180d69e085 Fix UnsupportedOperationException in AccountSetupBasic caused by Account.update() when !isSaved().
Bug 2001896.
Introduced by CL 8158.
2009-07-27 20:56:43 +02:00
Andrew Stadler
301ac18bb7 Create tests and improve docs on AttachmentProvider
No change in functionality.  Just getting a test infrastructure in place
before rewriting to use new EmailProvider.  Provides tests for:

* get type (raw & thumb)
* open file (raw)
* open file (thumb)
* query
* resolveAttachmentIdToContentUri
2009-07-27 11:20:15 -07:00
Android (Google) Code Review
c7ccb68ba4 Merge change 8253
* changes:
  Modified to display unread count correctly.
2009-07-24 14:46:52 -07:00
satok
41f775bbc7 Modified to display unread count correctly. 2009-07-25 06:42:34 +09:00
Marc Blank
b8a781f220 Load EAS attachments internally with new API ; re-sync after account changes
* Fix bugs #1993689 and #1997842
* Update test for attachment name creation
2009-07-24 12:36:52 -07:00
Mihai Preda
21ace307e0 Clean-up in MessageCompose, using EmailContent.Message.
Difficulties:
re-enable EmailHtmlUtil.resolveInlineImage() and
MessageCompose.loadAttachments() that operate on MIME parts.
2009-07-24 18:50:09 +02:00
Android (Google) Code Review
852974bc0b Merge change 8306
* changes:
  update the permissions for the AccountManagerService
2009-07-23 17:19:33 -07:00
Marc Blank
7375d950e4 Move to single EmailContent file; fix bug #1998157 2009-07-23 16:24:48 -07:00
Fred Quintana
ee37898bcb update the permissions for the AccountManagerService 2009-07-23 11:05:37 -07:00
Andrew Stadler
6ae38e4a39 Moving message operations into Controller, and load attachments.
* Moved logic into Controller:
  * toggling read/unread
  * toggling favorite status
  * some new unit tests
  * load attachment
* Completed logic for EAS to save attachments and MessageView to
  begin and complete that process.

NOTE:  Until EAS has a mode for saving the attachment locally (and I
rewrite the attachmentprovider to handle the new database) I am
implementing "view" attachment to just call "save".  This means that
attachments "viewed" will be dropped onto the SD card, instead of
cached and flushed.

TODO:  Controller is not properly working in its own thread, yet, so
we are not properly preventing ANR's yet.
2009-07-23 09:51:01 -07:00
Marc Blank
531ae9d25f Fix bug #1997284 re: single default account
* Fixed the bug and uncommented the relevant tests in ProviderTests
2009-07-22 16:35:12 -07:00
Andrew Stadler
9e2c6bd5f2 Remove saveOrUpdate from EmailContent to prevent stale writes
* Numerous classes modified to deal with this change
  * Fixes bugs 1993292 and 1994671
  * Renamed various setter and getter methods to reflect the underlying
    field names
  * Renamed syncFrequency to syncInterval in Account and Mailbox
  * Convenience method added to AccountSettings to save only user settings
  * Calls to content.update(context, content.toContentValues()), which save
    all fields, should be double-checked for correctness, making sure that
    content has current data and will not conflict with other threads that
    might modify that data
  * Ran all unit tests to confirm proper function

NOTE:  The logic to enforce single default account no longer works,
because that logic is in Account.save() and does not run via
Account.update().  I have patched out a small section of the relevant unit
test and will file a bug to come back for this fix.
2009-07-22 15:13:30 -07:00
Andrew Stadler
54c1f2bf9a Improvements to default account handling
* Remove all references to Account.mIsDefault, which was not the right
    way to find the default account (it is lazy initialized)
* Change Account.getDefaultAccount to getDefaultAccountId, which is more
    efficient and suitable in most uses.
* Wrote unit tests for provider default account handling

This should resolve bug 1983390 as well as a few other issues with default
account management.
2009-07-21 16:44:16 -07:00
Android (Google) Code Review
986a3b5f03 Merge change 8002
* changes:
  Prevent EAS startup race condition while debugging
2009-07-21 12:13:13 -07:00
Marc Blank
eda017627e Prevent EAS startup race condition while debugging
* Make sure that mAccount and mMailbox are up-to-date at all sync starts
* Prevent duplication of mailboxes in schema, since it's always wrong
* Add a service call to enable/disable logging in EAS
2009-07-21 12:00:16 -07:00
Andrew Stadler
4e4abc645c Clean up launch-time & account setup behaviors.
* Moved welcome message into account setup basics (name/pass)
* Reworked Welcome to go to AccountSetupBasics on count=0
* In AccountFolderList, removed old welcome message code, and add
  code to launch AccountSetupBasics when last account is deleted
* Fixed shortcut picker so launcher shortcuts work again
* Reimplemented shortcut receiver (in MessageList now)
* Default EAS accounts to SSL

Addresses bug 1916583 & 1987440
2009-07-21 11:06:14 -07:00
Marc Blank
28fc7799ce Add support for the flag (favorite) property in EAS 12; cleanup
* Support flag property in Exchange 2007 (EAS 12)
* Support startSync/stopSync/reloadFolderList in EAS service
* Cleanup files a little bit
2009-07-20 17:45:43 -07:00
Marc Blank
5790d1458f Work on EmailService calls, attachment loading, etc.
* Stubbed in attachment loading in MessageView for EAS messages
* Modified MessageView.Listener to implement IEmailServiceCallback
  for testing callback functionality
* Rewrote EmailServiceProxy entirely
* Simplified loadAttachment service call
2009-07-20 13:52:27 -07:00
Marc Blank
53093871c4 Changes to EAS: attachments, HTML text, and sending mail (without atts)
* Added HTML support for Exchange 2007 and later
* Modified MessageView to show HTML parts of body (if present)
* Replace some unused convenience methods in Body to be ones that are more
  useful (i.e. retrive body for a given message id)
* Made EAS sending operational
* Updated SyncManager to recognize the creation of new messages and check
  for work to be done (i.e. starting Outbox sync)
* Modified MessageView to remove EmailContent.X references
* Also changed the pattern EmailContent.getContent(cursor, class) to the better
  new ClassName().restore(cursor)
* Add a test of the utility to determine mime type from file name (since
  EAS doesn't provide this with attachment header information)
* Fixed bug in ProviderTestUtils in which the base (EmailContent) fields weren't
  being checked for equality in the various subclass equality testers.  Fixed a
  bug in saving emails that was caught by fixing this bug.
2009-07-18 23:31:39 -07:00
Android (Google) Code Review
d10ffd33de Merge change 7780
* changes:
  resolved conflicts for Email MessagingController null check from donut to master
2009-07-17 16:51:47 -07:00
Andrew Stadler
7e91c121bb Enable listing attachments in MessageView
* Rename internal helper class from Attachment to AttachmentInfo
* After message loads, query for Attachments
* Play back cursor adding attachments
* Commented out almost everything else related to loading or opening them
2009-07-17 16:39:31 -07:00
Brett Chabot
035ce8bcd1 resolved conflicts for Email MessagingController null check from donut to master 2009-07-17 16:18:41 -07:00
Brett Chabot
8a3b8992f9 Add null check when initializing email messaging controller visible limits.
This is to fix the NPE that would often occur during test runs. I believe the
root cause is mock accounts would be created by some email unit tests that did
not have values for all fields. Before these accounts were deleted, the main
email thread would try to access them and blow up with a NPE.
2009-07-17 11:12:07 -07:00
Andrew Stadler
4119218e2f Add support for get-attachments-by-message-id
* clean up provider URI's in this area
* minor bugfix in EmailContent, and add auto-writeback of messageId into
    saved attachments
* clean up existing attachment unit tests
* add new tests
2009-07-16 16:03:40 -07:00
Android (Google) Code Review
d4c18546fb Merge change 7580
* changes:
  Eliminate Config.LOGV (deprecated, always false). Add Email.LOGD as a development log guard.
2009-07-16 14:51:12 -07:00
Mihai Preda
f33986d5cc Eliminate Config.LOGV (deprecated, always false).
Add Email.LOGD as a development log guard.
2009-07-16 14:09:15 -07:00
Android (Google) Code Review
0dba37ec51 Merge change 7552
* changes:
  Fix push bug, minor changes to logging and removal of debug code
2009-07-16 13:14:55 -07:00
Marc Blank
6a6d67edde Fix push bug, minor changes to logging and removal of debug code 2009-07-16 13:13:54 -07:00
Andrew Stadler
3c27c65426 Small cleanups to POP/IMAP sync.
* Close after sync, so next sync will open and update message count.
2009-07-16 10:19:19 -07:00
Marc Blank
976f92908d Add support for attachments in EmailProvider and (preliminary) EAS
* EmailProvider now saves Attachment records atomically with Message (and Body,
  of course) if an ArrayList is stored in mAttachments
* Update EAS code to support attachment discovery
* Update EAS code to support attachment download via service API (preliminary)
* Add test for atomic attachment save
* Add test for unique file creation (external)
2009-07-16 00:01:57 -07:00
Android (Google) Code Review
c5f783f022 Merge change 6675
* changes:
  First steps towards using the new EmailContent.Message in MessageCompose.
2009-07-15 14:13:31 -07:00
Andrew Stadler
f2fdd899ef Clean up new account creation & initial sync.
* Give MessageList the ability to do a folder scan (from server)
    in order to "find" the inbox after account creation.
* Don't show messages that haven't even been partially downloaded yet
    (reduces flicker during POP initial sync)
* Move some folder lookup code (in MessageList) out of UI thread
* Restore simple color chip code so multiple accounts look good
    in MessageList
2009-07-15 13:28:55 -07:00
Mihai Preda
c6893ddf0f First steps towards using the new EmailContent.Message in MessageCompose. 2009-07-15 13:13:45 -07:00
Marc Blank
16470fc7db Fix bugs related to EAS upsync and the cleanup afterward. 2009-07-14 17:24:16 -07:00
Marc Blank
6b158f715b Handle UI delete in EAS where the message is moved to trash
* Check for the folder of updated messages, and delete those now in trash
* Created convenience method for finding a mailbox of a particular type in
  an account (helpful for finding, say, an Inbox or Trash for a given account
* Fix deleted/updated message table so that the _id column is defined to be
  unique (to prevent duplicate change records from being written)
2009-07-14 16:04:27 -07:00
Marc Blank
316bb44e1a Use MatrixCursor instead of (internal) ArrayListCursor 2009-07-14 14:49:34 -07:00
Andrew Stadler
2999db7866 Add Summary Section to AccountFolderList ("at a glance")
* Wrap group cursor in a MergeCursor to insert 1st row
* Clean up a few loose ends (e.g. no longpress on summary row)
* Implement the summaries child cursor
* Add special queries to MessageList for Inbox, Unread, Favorites

There are *a lot* of TODO's in this checkin;  I just wanted to get some
basic UI up and running so we could start to explore issues created by
the new configuration.  A lightweight sampling:
* Aggregrate filters (e.g. all inboxes) need to be handled in the
provider, instead of with the current two-query hack.
* We'll need a lot of UI cleanup, e.g. different contextual menus
* We'll need to generalize some of the code in order to more easily
support repeating the same compound queries - e.g. MessageView actually
needs the same query in order to enable the next/prev buttons.
2009-07-14 11:44:07 -07:00
Andrew Stadler
17250429db Various EAS related changes related to accounts and services.
* Renamed ISyncManager/ISyncManagerCallback to IEmailService/IEmailServiceCallback
* Restored ExchangeTransportExample to its original state; created ExchangeStore to
  handle validation functionality instead; updated stores.xml to reflect these changes.
* Add support for AccountManager in EAS code (this is necessary for the contacts and
  calendar providers to work with syncable data); created EasAuthenticatorService to
  as our authenticator, which required adding authenticator.xml and modifying the
  manifest to register our service with AccountManager metadata
* Created EmailServiceProxy as a convenience for the UI in calling into the EAS
  service; created EmailServiceStatus class for status codes in callbacks.
2009-07-13 19:10:08 -07:00
Andrew Stadler
ded3c915d8 Add folders to AccountFolderList
* Scan folders and write into child cursors
* Clicking a folder takes you to MessageList
* Remove most links to FolderMessageList (nearly dead!)
* Repair 1-account startup behavior (takes you directly to inbox)
* Cleanup a few basic things like context menus & refresh

TODO: Magic mailbox section at the top
TODO: As always, better linkage to sync engine(s)
TODO: Menus, context menus, etc.
TODO: Proper handling of expandable list - accounts should stay open?
2009-07-10 16:46:51 -07:00
Andrew Stadler
72dce73390 Convert Accounts to AccountFolderList
* Move relevant sources & resources to new name
* Convert from ListView to ExpandableListView
* No children yet - selecting account simply jumps to FML (temp)
* No other change to functionality (e.g. no menu changes yet)
2009-07-09 12:33:09 -07:00
Andrew Stadler
b55bfc96f4 Enable multi-selection actions
* Toggle small pane with multi-select action buttons
* Implement multi-read/unread
* Implement multi-favorites (stars)
* Implement multi-delete

TODO: menu items when there are selected items
2009-07-08 16:09:45 -07:00
Mihai Preda
e8d58c01ec Implement efficient Address pack/unpack and unit-test it.
Also unit-test legacy pack/unpack.
2009-07-08 12:07:58 -07:00
Andrew Stadler
432d1ec3ed Add custom item view to MessageList
* Stores per-message metadata
* Fix a number of todo's in MessageList
* Clicking on checkbox toggles state, updates checked list
* clicking on star toggles favorite state

To do:  When one or more messages are checked, we should slide in a
panel with action buttons.
2009-07-07 13:43:24 -07:00
Andrew Stadler
a396a9bf14 Minor cleanups (layout only) 2009-07-07 11:36:04 -07:00
Android (Google) Code Review
5e444dd794 Merge change 5793
* changes:
  Major refactor and cleanup of EAS code
2009-07-07 11:17:48 -07:00
Marc Blank
b6493a07ef Major refactor and cleanup of EAS code
* Rewrote push logic to encompass multiple folders (i.e. calendar/contacts)
    * Change inbox from push frequency to ping frequency after initial sync
    * Implement upsync logic for email (i.e. sending changes to the server)
    * Did cleanup of some files (there's still some to do) re: format, style
    * Initial one-way sync of Contacts data - add and delete are implemented
    * Created adapter package for all parts of the EAS adapter
    * Created utility package for utility code that will eventually be merged
      with code in the Email application (Base64, QuotedPrintable, etc.)
    * SyncManager/AbstractSyncService can be used in the future for other
      protocols, especially IMAP push
2009-07-07 00:30:24 -07:00
Andrew Stadler
61e6ff4521 Fixed minor typo in MessageView 2009-07-06 19:02:16 -07:00
Andrew Stadler
7c3cca80a0 Reenable delete-message UI and write delete-from-provider.
* Longpress delete in MessageList
* Delete or Menu-Delete in MessageView
* Add deleteMessage() to Controller
* Unit tests for the new code in Controller
2009-07-06 13:58:30 -07:00
Andrew Stadler
45f9dd22e1 Fix bug in GroupMessagingListener and add unit tests 2009-07-02 14:29:02 -07:00
Andrew Stadler
bb0f962dbb Enable message read/unread toggling
* Automatically marked read when entering MessageView
* Marked unread via menu selected during MessageView
* Provider updated (directly - see note)
* Enable context menu in MessageList and enable "open" & toggle unread

NOTE: Does not use the correct service notifications yet;  Just updates
the providers.

NOTE: The UI for the context menu is incomplete, it says "mark as read"
but it actually toggles the state.  The true UI is to flip the text to
match the current state e.g. "mark as read" or "mark as unread".  That
will be much simpler to implement when we switch to a custom list item
view class, where we can cache the read/unread state (and other tidbits).
2009-07-01 16:04:30 -07:00
Andrew Stadler
48c8cc34b7 Add "favorite" star to MessageView
* Shown next to subject (non-final layout)
* Value taken from provider data
* Tapping star toggles state
* State writes back to provider

NOTE:  I am currently doing the provider writeback via direct provider
calls (using the synced-message URI) but not doing it with a service call,
so at this point there is no triggering of any server-side update.
However a sync engine might "discover" the change.

NOTE:  I made a global change of "mMessage" to "mOldMessage" because
there is still a lot of legacy code in MessageView and I wanted to clearly
demarcate the code that still needs to be redone.
2009-07-01 12:11:47 -07:00