From 7b79163aac1542577304d60fa76de6feb6be48c7 Mon Sep 17 00:00:00 2001 From: Marc Blank Date: Mon, 21 Sep 2009 10:39:10 -0700 Subject: [PATCH] Show "sync contacts" setting properly in the settings page Change-Id: I9c198e7795a8f2ea348361092eae22c8ff22a1a0 --- src/com/android/email/activity/setup/AccountSettings.java | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/com/android/email/activity/setup/AccountSettings.java b/src/com/android/email/activity/setup/AccountSettings.java index 5a8bf7831..17d7b9c8e 100644 --- a/src/com/android/email/activity/setup/AccountSettings.java +++ b/src/com/android/email/activity/setup/AccountSettings.java @@ -247,9 +247,8 @@ public class AccountSettings extends PreferenceActivity { mSyncContacts = (CheckBoxPreference) findPreference(PREFERENCE_SYNC_CONTACTS); if (mAccount.mHostAuthRecv.mProtocol.equals("eas")) { - String login = mAccount.mHostAuthRecv.mLogin; android.accounts.Account acct = - new android.accounts.Account(login, Eas.ACCOUNT_MANAGER_TYPE); + new android.accounts.Account(mAccount.mEmailAddress, Eas.ACCOUNT_MANAGER_TYPE); mSyncContacts.setChecked(ContentResolver .getSyncAutomatically(acct, ContactsContract.AUTHORITY)); } else { @@ -319,9 +318,8 @@ public class AccountSettings extends PreferenceActivity { mAccount.setFlags(newFlags); if (mAccount.mHostAuthRecv.mProtocol.equals("eas")) { - String login = mAccount.mHostAuthRecv.mLogin; android.accounts.Account acct = - new android.accounts.Account(login, Eas.ACCOUNT_MANAGER_TYPE); + new android.accounts.Account(mAccount.mEmailAddress, Eas.ACCOUNT_MANAGER_TYPE); ContentResolver.setSyncAutomatically(acct, ContactsContract.AUTHORITY, mSyncContacts.isChecked());