Back to project page androidify-yourself.
The source code is released under:
MIT License
If you think the Android project androidify-yourself listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.github.androidify; /*from ww w . ja v a 2s . c o m*/ import android.support.v4.app.Fragment; import android.support.v4.app.FragmentManager; import android.support.v4.app.FragmentPagerAdapter; import java.util.List; public class AndroidifyViewPagerAdapter extends FragmentPagerAdapter { private List<Integer> imgIds; public AndroidifyViewPagerAdapter(FragmentManager fm, List<Integer> imgIds) { super(fm); this.imgIds = imgIds; } @Override public Fragment getItem(int position) { AndroidifyViewPagerItemFragment fragment = new AndroidifyViewPagerItemFragment(); fragment.setImgId(imgIds.get(position)); return fragment; } @Override public int getCount() { return imgIds.size(); } }