Home | History | Annotate | Download | only in service

Lines Matching refs:accountId

117      * @param accountId account to clear, or -1 for all accounts

119 public static void resetNewMessageCount(Context context, long accountId) {
122 if (accountId == -1 || accountId == report.accountId) {
129 if (accountId == -1) {
132 uri = ContentUris.withAppendedId(Account.CONTENT_URI, accountId);
143 * @param accountId the id of the account that is reporting new messages
146 public static void actionNotifyNewMessages(Context context, long accountId) {
149 i.putExtra(EXTRA_CHECK_ACCOUNT, accountId);
218 long accountId = intent.getLongExtra(EXTRA_CHECK_ACCOUNT, -1);
221 ContentUris.withAppendedId(Account.CONTENT_URI, accountId),
229 accountId = -1;
235 Log.d(LOG_TAG, "notify accountId=" + Long.toString(accountId)
238 if (accountId != -1) {
239 updateAccountReport(accountId, newMessageCount);
240 notifyNewMessages(accountId);
284 AccountSyncReport oldReport = oldSyncReports.get(newReport.accountId);
307 long[] accountInfo = new long[numAccounts * 2]; // pairs of { accountId, lastSync }
334 accountInfo[accountInfoIndex++] = report.accountId;
344 long idToCheck = (nextAccount == null) ? -1 : nextAccount.accountId;
366 * @param accountId the account we were trying to check
369 private void setWatchdog(long accountId, AlarmManager alarmMgr) {
370 PendingIntent pi = createAlarmIntent(accountId, null, true);
417 long accountId;
434 return displayName + ": id=" + accountId + " prevSync=" + prevSyncTime
443 * @param accountId -1 will rebuild the list if empty. other values will force loading
446 /* package */ void setupSyncReports(long accountId) {
448 setupSyncReportsLocked(accountId);
455 private void setupSyncReportsLocked(long accountId) {
456 if (accountId == -1) {
463 if (mSyncReports.containsKey(accountId)) {
470 if (accountId == -1) {
473 uri = ContentUris.withAppendedId(Account.CONTENT_URI, accountId);
496 report.accountId = acctId;
512 mSyncReports.put(report.accountId, report);
522 * @param accountId the account being updated
526 /* package */ AccountSyncReport updateAccountReport(long accountId, int newCount) {
528 setupSyncReports(accountId);
530 AccountSyncReport report = mSyncReports.get(accountId);
533 Log.d(LOG_TAG, "No account to update for id=" + Long.toString(accountId));
571 long accountId = accountInfo[accountInfoIndex++];
573 AccountSyncReport report = mSyncReports.get(accountId);
597 public void updateMailboxCallback(MessagingException result, long accountId,
602 accountId, Mailbox.TYPE_INBOX);
605 updateAccountReport(accountId, numNewMessages);
607 notifyNewMessages(accountId);
610 updateAccountReport(accountId, -1);
618 public void updateMailboxListCallback(MessagingException result, long accountId,
622 public void serviceCheckMailCallback(MessagingException result, long accountId,
628 updateAccountReport(accountId, -1);
640 public void sendMailCallback(MessagingException result, long accountId, long messageId,
651 private void notifyNewMessages(long accountId) {
666 if (report.accountId == accountId) {
689 intent = MessageList.createIntent(this, accountId, -1, Mailbox.TYPE_INBOX);