Make tapping account keep inbox highlight.
Previously, if you were in the default inbox
of an account and tapped that account in two-pane
mode, the highlight on the default inbox would disappear
because we tried to compare a Uri to a FolderUri (which
always fails).
Change-Id: I2040896c008ac805c4facff0dd3e9cb944c48ece
diff --git a/src/com/android/mail/ui/FolderListFragment.java b/src/com/android/mail/ui/FolderListFragment.java
index 74c00ec..766660f 100644
--- a/src/com/android/mail/ui/FolderListFragment.java
+++ b/src/com/android/mail/ui/FolderListFragment.java
@@ -484,14 +484,9 @@
// Account, so switch.
folder = null;
final Account account = drawerItem.mAccount;
-
- if (account != null && account.settings.defaultInbox.equals(mSelectedFolderUri)) {
- // We're already in the default inbox for account, just re-check item ...
- final int defaultInboxPosition = position + 1;
- if (mListView.getChildAt(defaultInboxPosition) != null) {
- mListView.setItemChecked(defaultInboxPosition, true);
- }
- // ... and close the drawer (no new target folders/accounts)
+ if (account != null && mSelectedFolderUri.equals(account.settings.defaultInbox)) {
+ // We're already in the default inbox for account,
+ // just close the drawer (no new target folders/accounts)
mAccountController.closeDrawer(false, mNextAccount,
getDefaultInbox(mNextAccount));
} else {