Notify when message changes (mostly for saving drafts)
b/10785769 Change-Id: I1ad8e0583ddaa9fa4fcc45906745980f103ec1fa
This commit is contained in:
parent
26ee7c9875
commit
c637bff198
|
@ -3702,6 +3702,7 @@ public class EmailProvider extends ContentProvider {
|
|||
} else {
|
||||
c = db.rawQuery(sql, new String[] {id});
|
||||
}
|
||||
notifyUri = UIPROVIDER_MESSAGE_NOTIFIER.buildUpon().appendPath(id).build();
|
||||
break;
|
||||
case UI_ATTACHMENTS:
|
||||
final List<String> contentTypeQueryParameters =
|
||||
|
@ -3962,6 +3963,8 @@ public class EmailProvider extends ContentProvider {
|
|||
LogUtils.d(TAG, "applyBatch exception");
|
||||
}
|
||||
}
|
||||
notifyUIMessage(msg.mId);
|
||||
|
||||
if (mailbox.mType == Mailbox.TYPE_OUTBOX) {
|
||||
startSync(mailbox, 0);
|
||||
final long originalMsgId = msg.mSourceKey;
|
||||
|
@ -4511,6 +4514,14 @@ public class EmailProvider extends ContentProvider {
|
|||
notifyWidgets(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* Notify about the message id passed in
|
||||
* @param id the message id to be notified
|
||||
*/
|
||||
private void notifyUIMessage(long id) {
|
||||
notifyUI(UIPROVIDER_MESSAGE_NOTIFIER, id);
|
||||
}
|
||||
|
||||
/**
|
||||
* Notify about the Account id passed in
|
||||
* @param id the Account id to be notified
|
||||
|
|
Loading…
Reference in New Issue