Update sync state immediately after accounts are shown

Bug: 18251114
Change-Id: I13791ff3979ce862e11989a3819f2356be32a0f4
This commit is contained in:
Alexandra Gherghina
2014-11-07 15:24:27 +00:00
parent c66eb698a9
commit 6002ff8dce

View File

@@ -104,6 +104,7 @@ public class ManageAccountsSettings extends AccountPreferenceBase
mAuthenticatorHelper.listenToAccountUpdates();
updateAuthDescriptions();
showAccountsIfNeeded();
showSyncState();
}
@Override
@@ -234,6 +235,10 @@ public class ManageAccountsSettings extends AccountPreferenceBase
showSyncState();
}
/**
* Shows the sync state of the accounts. Note: it must be called after the accounts have been
* loaded, @see #showAccountsIfNeeded().
*/
private void showSyncState() {
// Catch any delayed delivery of update messages
if (getActivity() == null || getActivity().isFinishing()) return;