I have managed to show the edges of the next and previous pages by setting a negative page margin. However, the problem is that if I scroll page 1 to the left such that now page 2 is in the center, like so:
0 - [ 1 ] - 2 ---> 1 - [ 2 ] - 3
, then page '3' is loaded ONLY after 2 arrives at the center and the swipe ends. This causes a jarring "appear" of page '3' (instead of smoothly sliding in).
How do I have page '3' loaded so that animation is smooth?
Have you tried setOffscreenPageLimit()
on ViewPager
?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With