0
I never tried this but can you try this.
private void getUnreadCount(String selectedAccount, Context context) {
Log.d("Gmail - " + selectedAccount);
Cursor labelsCursor = context.getContentResolver().query(GmailContract.Labels.getLabelsUri(selectedAccount), null, null, null, null...