Skip to content

Commit

Permalink
MainActivity: Remove setOffscreenPageLimit (fixes #327) (fixes #321)
Browse files Browse the repository at this point in the history
  • Loading branch information
Catfriend1 committed Feb 19, 2019
1 parent 88677c9 commit 53d3c13
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,11 @@ public CharSequence getPageTitle(int position) {
};
try {
mViewPager.setAdapter(mSectionsPagerAdapter);
mViewPager.setOffscreenPageLimit(numPages);
/**
* See issues #321, #327
* Call stack on IllegalStateException: onServiceStateChange/updateViewPager/setOffscreenPageLimit
*/
// mViewPager.setOffscreenPageLimit(numPages);
} catch (IllegalStateException e) {
/**
* IllegalStateException happens due to a bug in FragmentStatePagerAdapter.
Expand Down

0 comments on commit 53d3c13

Please sign in to comment.