b/12723917. Make sure that explicit request to sync from our code
sets manual to true.  This solves the problem of sync requests being
dropped on the floor if email sync is disabled but something like
calendar is still enabled.

Change-Id: Ia8584e2f11e5ca46d43e91738986fbb53d465c57
diff --git a/src/com/android/exchange/eas/EasOperation.java b/src/com/android/exchange/eas/EasOperation.java
index 97df766..7a6cc5b 100644
--- a/src/com/android/exchange/eas/EasOperation.java
+++ b/src/com/android/exchange/eas/EasOperation.java
@@ -696,6 +696,15 @@
     protected static void requestSyncForMailboxes(final android.accounts.Account amAccount,
             final ArrayList<Long> mailboxIds) {
         final Bundle extras = Mailbox.createSyncBundle(mailboxIds);
+        /**
+         * Please note that it is very possible that we are trying to send a request to the
+         * email sync adapter even though email push is turned off (i.e. this account might only
+         * be syncing calendar or contacts). In this situation we need to make sure that
+         * this request is marked as manual as to ensure that the sync manager does not drop it
+         * on the floor. Right now, this function is only called by EasPing, if it is every called
+         * by another caller, then we should reconsider if manual=true is the right thing to do.
+         */
+        extras.putBoolean(ContentResolver.SYNC_EXTRAS_MANUAL, true);
         ContentResolver.requestSync(amAccount, EmailContent.AUTHORITY, extras);
         LogUtils.i(LOG_TAG, "requestSync EasOperation requestSyncForMailboxes  %s, %s",
                 amAccount.toString(), extras.toString());