@Override
    public int getCount() {
        // warning: scrolling to very high values (1,000,000+) results in
        // strange drawing behaviour
        return Integer.MAX_VALUE;
    }
A PagerAdapter that wraps around another PagerAdapter to handle paging wrap-around.
Thanks to: https://github.com/antonyt/InfiniteViewPager
library/src/main/java/com/daimajia/slider/library/Tricks/InfinitePagerAdapter.java