Support the new MOVE_FAILED_TO_DRAFT operation in Email

Default the MOVE_FAILED_TO_DRAFT action to simply deleting
the failed message from Outbox for Email since this is the
current behavior.

b/4080109

Change-Id: I74917d0b2581e2dd145906dddfac395efc2d8206
This commit is contained in:
Jin Cao 2014-06-04 16:33:19 -07:00
parent bc65885e24
commit 99e882e22d
1 changed files with 3 additions and 1 deletions

View File

@ -5246,7 +5246,9 @@ public class EmailProvider extends ContentProvider
// Another special case - deleting a draft.
final String operation = values.getAsString(
UIProvider.ConversationOperations.OPERATION_KEY);
if (UIProvider.ConversationOperations.DISCARD_DRAFTS.equals(operation)) {
// TODO: for now let's just default to delete for MOVE_FAILED_TO_DRAFT operation
if (UIProvider.ConversationOperations.DISCARD_DRAFTS.equals(operation) ||
UIProvider.ConversationOperations.MOVE_FAILED_TO_DRAFTS.equals(operation)) {
uiDeleteMessage(uri);
return 1;
}