summaryrefslogtreecommitdiff
path: root/java/com/android/dialer/app/list
diff options
context:
space:
mode:
authormaxwelb <maxwelb@google.com>2017-10-18 18:00:47 -0700
committerEric Erfanian <erfanian@google.com>2017-10-19 08:40:02 -0700
commit88041ae80c81fc4dfab1e17f937baa35688b0040 (patch)
tree7f16f98729404c79ed9d2d8dd6894e05a4049539 /java/com/android/dialer/app/list
parentb8337d12753806ac478621a0a1e53a5d9b21c996 (diff)
Automated g4 rollback of changelist 172154863.
*** Reason for rollback *** Causes crashes on rotation: http://b/67839843 *** Original change description *** Do not load every DialtactsActivity fragment on app open With this change we now only load the Favorites and Call Log Fragments when the app opens. Paging to the CallLogFragment makes the ContactsFragment load as we would want. This should result in a faster app start time. I'll need to verify the impact of this using the same method as http://cl/170422671 I verified the change in behavior by adding my own log line to the onCreate of each Fragment. I saw all of them get created before the ch... *** Bug: 64541209,65460373 Test: Manually verified regression fixed PiperOrigin-RevId: 172684553 Change-Id: I9a5b30d6619d930adfb82b19ac3ff9da00decaaa
Diffstat (limited to 'java/com/android/dialer/app/list')
-rw-r--r--java/com/android/dialer/app/list/ListsFragment.java6
1 files changed, 1 insertions, 5 deletions
diff --git a/java/com/android/dialer/app/list/ListsFragment.java b/java/com/android/dialer/app/list/ListsFragment.java
index 05c647aec..362997a5a 100644
--- a/java/com/android/dialer/app/list/ListsFragment.java
+++ b/java/com/android/dialer/app/list/ListsFragment.java
@@ -203,11 +203,7 @@ public class ListsFragment extends Fragment implements OnPageChangeListener, Lis
mPrefs.getBoolean(
VisualVoicemailEnabledChecker.PREF_KEY_HAS_ACTIVE_VOICEMAIL_PROVIDER, false));
mViewPager.setAdapter(mAdapter);
-
- // This is deliberate. See cl/172018946 for the app startup implications of using 1 here
- // versus loading more fragments upfront.
- mViewPager.setOffscreenPageLimit(1);
-
+ mViewPager.setOffscreenPageLimit(DialtactsPagerAdapter.TAB_COUNT_WITH_VOICEMAIL - 1);
mViewPager.addOnPageChangeListener(this);
showTab(DialtactsPagerAdapter.TAB_INDEX_SPEED_DIAL);