Commit Graph

41 Commits

Author SHA1 Message Date
Mihai Preda fa2238ca40 Email: BUG 1964940 Support multiple share from Gallery in Email 2009-09-02 15:38:48 +02:00
Mihai Preda 948e5ae63b MessageCompose: BUG 2069196, compose email from the correct account. 2009-08-28 01:29:33 +02: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 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
Andrew Stadler 4b41bae270 Enable IMAP/POP sending and EAS resend
* Finish IMAP/POP sections of Controller.sendMessage
* Rewrite MessagingController.sendPendingMessagesSynchronous
* Add deleteAllAttachmentFiles to AttachmentProvider, and unit test
* Rework sendMessage callbacks and integrate into MessageList UI
* Send pending from UI

TODO:
* Find other places from which to call deleteAllAttachmentFiles
2009-08-20 11:09:39 -07:00
Mihai Preda 44144d0301 MessageCompose: initial save attachments and load them back.
- load attachments for EditDraft.
- save attachments when save message.
- unit test for restoreAccountsWithMessageId()
2009-08-20 15:52:50 +02:00
Andrew Stadler 46d7d7f1b6 Rework service to use provider accounts and controller.
* Rewrite service logic to select and update one account at a time
* Add checkmail API to Controller, and much rework/cleanup of existing
   callback API's
* Rewrite notification posting code
* Rewire connection to MessageList to be opened by notifications, to
   cancel notifications, and to reset the "new message" count whenever
   an account is viewed.
* Boilerplate cleanup to a lot of activities because they share the
   callbacks that have had minor changes.
* Remove old push controls from Store API

In progress:
* To provide notification mechanism for EAS pushed mail
2009-08-18 00:54:34 -07:00
Mihai Preda 9627d014e1 MessageCompose: update body on save.
- plus unit tests.
- and some attachment refactoring.
- move PROJECTION_ID up to EmailContent.
- add index on messageKey to Attachments and Body tables.
- add missing Columns.ID field in EmailContent.
2009-08-17 13:43:56 +02: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
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
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
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
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
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 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
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
Mihai Preda c6893ddf0f First steps towards using the new EmailContent.Message in MessageCompose. 2009-07-15 13:13:45 -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
Mihai Preda ed0e683d86 Don't drop invalid addresses while editing & check that all addresses are valid before send.
BUG: 1542391
add unit tests.
2009-06-24 15:44:08 -07:00
Marc Blank a290f503f1 Refactored EmailStore, EmailContent, EmailProvider
EmailStore goes away, replaced by EmailContent
All database activity is moved to EmailProvider
2009-06-15 14:49:11 -07:00
Andrew Stadler 68a9ccfcde final cleanups to get basic message operations working properly.
* Generate compatibility UUID early enough to stick, so our localstore
db's are created correctly and not recreated over and over again.
* Compose menu items working
* Fix single-account mode (go straight to inbox)
* Lightweight Account projections where possible
* Properly show/hide default account checkbox (during new acct screens)

What works:
* All unit tests
* Editing existing accounts
* Create new accounts
* Checking account settings against server
* Mail sync using accounts
* Viewing mailboxes
* Viewing messages
* Composing messages

What breaks (in approx order of planned fixes)
* Some details of account editing
* Import of existing accounts
2009-06-09 16:13:05 -07:00
Andrew Stadler c0033f24a2 Convert remainder of app to use provider-based accounts
What works:
* Unit tests, except for com.android.email.activity.setup.*
* Editing existing accounts
* Create new accounts
* Checking account settings against server
* Mail sync using accounts
* Viewing mailboxes

What breaks (in approx order of planned fixes)
* Unit tests in com.android.email.activity.setup.*
* Viewing messages
* Composing messages
* Some details of account editing
* Import of existing accounts
2009-06-08 15:42:40 -07:00
Mihai Preda 7ac2b6e048 am a9576bda: resolved conflicts for merge of 7403a54738 to donut
Merge commit 'a9576bdad6d9711c9e790fdbad3cbb1ab5c5fb03'

* commit 'a9576bdad6d9711c9e790fdbad3cbb1ab5c5fb03':
  AI 149664: Move escapeChar from MessageView to EmailHtmlUtil.
2009-06-08 12:23:43 -07:00
Mihai Preda 7403a54738 AI 149664: Move escapeChar from MessageView to EmailHtmlUtil.
Integrate CL 148437 from DocomoEmail.
  BUG=1860250

Automated import of CL 149664
2009-06-08 11:21:18 -07:00
Mihai Preda da93b380d1 am 23a27697: Merge branch \'readonly-p4-donut\' into donut
Merge commit '23a27697963642d6450b70dd83709492c1bdde72'

* commit '23a27697963642d6450b70dd83709492c1bdde72':
  AI 149607: Add relevant title to attachment file chooser.
2009-06-05 11:41:33 -07:00
Mihai Preda a00eb291f1 AI 149607: Add relevant title to attachment file chooser.
Delete the original source message only when the message is in Drafts folder.
  If the original message is in the other folder than Drafts, it should be
  retained.
  Integrates 149194,149306,149459 from DocomoEmail.
  BUG=1860250,1887835

Automated import of CL 149607
2009-06-05 11:36:17 -07:00
Mihai Preda 372c12bfbb am a15503a4: Merge branch \'readonly-p4-donut\' into donut
Merge commit 'a15503a4a6cf46e810bde4aedc846680ed288c1c'

* commit 'a15503a4a6cf46e810bde4aedc846680ed288c1c':
  AI 149578: Fixed possible NullPointerException in MessageCompose.
2009-06-04 22:43:34 -07:00
Mihai Preda e6ec9d86e8 AI 149578: Fixed possible NullPointerException in MessageCompose.
Integrates 148996,149295 from imode email.
  BUG=1862155,1798576,1860250

Automated import of CL 149578
2009-06-04 12:48:20 -07:00
Andrew Stadler 9019315b26 Conversion to provider-based Account. What works:
* Editing existing accounts
 * Two placeholder accounts are written

What breaks (in approx order of planned fixes)
 * Some details of account editing
 * New account creation,
 * Viewing mailboxes & messages
 * Mail sync using accounts
 * Import of existing accounts
2009-06-03 16:11:36 -07:00
Mihai Preda 7436601fae AI 149523: Correctly display inline images in Reply and Forward messages.
Integrates CL 148436, 148515, 148833 from imode email.
  BUG=1814789,1860250

Automated import of CL 149523
2009-06-03 06:44:47 -07:00
Andy Stadler 7265bb729b Automated import from //branches/donutburger/...@142152,142152 2009-03-24 21:31:47 -07:00
The Android Open Source Project 3b85e2c2b5 auto import from //branches/cupcake_rel/...@138607 2009-03-13 13:04:24 -07:00
The Android Open Source Project 3debc4f25a auto import from //branches/cupcake/...@137873 2009-03-11 12:11:58 -07:00
The Android Open Source Project 96c5af40d6 auto import from //depot/cupcake/@135843 2009-03-03 19:32:22 -08:00
The Android Open Source Project 8c2158a5eb auto import from //depot/cupcake/@135843 2009-03-03 18:28:50 -08:00
The Android Open Source Project 88a1d6f92d auto import from //branches/cupcake/...@132276 2009-02-19 10:57:35 -08:00
The Android Open Source Project f7ae27b973 auto import from //branches/cupcake/...@130745 2009-02-10 15:44:04 -08:00
The Android Open Source Project 687f9962d7 Code drop from //branches/cupcake/...@124589 2008-12-17 18:05:56 -08:00
The Android Open Source Project 8978aac197 Initial Contribution 2008-10-21 07:00:00 -07:00