diff options
author | daneren2005 <daneren2005@gmail.com> | 2013-07-01 13:01:02 -0700 |
---|---|---|
committer | daneren2005 <daneren2005@gmail.com> | 2013-07-01 13:01:02 -0700 |
commit | 9bebdf720ee3326445729a1ca5c046c97d8f503d (patch) | |
tree | 88c5deb97f22ae363a5e85cee2678986ba17f914 | |
parent | ba540b9b9218756c479b98616fe9f1000cab0d2d (diff) | |
download | dsub-9bebdf720ee3326445729a1ca5c046c97d8f503d.tar.gz dsub-9bebdf720ee3326445729a1ca5c046c97d8f503d.tar.bz2 dsub-9bebdf720ee3326445729a1ca5c046c97d8f503d.zip |
Stop ViewPager from destroying off screen fragments
-rw-r--r-- | subsonic-android/src/github/daneren2005/dsub/activity/MainActivity.java | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/subsonic-android/src/github/daneren2005/dsub/activity/MainActivity.java b/subsonic-android/src/github/daneren2005/dsub/activity/MainActivity.java index 3b6a456d..edbf216a 100644 --- a/subsonic-android/src/github/daneren2005/dsub/activity/MainActivity.java +++ b/subsonic-android/src/github/daneren2005/dsub/activity/MainActivity.java @@ -149,6 +149,7 @@ public class MainActivity extends SubsonicActivity { }); viewPager = (ViewPager) findViewById(R.id.pager); + viewPager.setOffscreenPageLimit(4); pagerAdapter = new TabPagerAdapter(this, viewPager); viewPager.setAdapter(pagerAdapter); viewPager.setOnPageChangeListener(pagerAdapter); |