Skip to content

Instantly share code, notes, and snippets.

@Dmuasya

Dmuasya/MainActivity.java Secret

Created Dec 23, 2020
Embed
What would you like to do?
public class MainActivity extends FragmentActivity {
private String[] mTitles = new String[] { "Tab 1", "Tab 2", "Tab 3" };
private SimpleViewPagerIndicator mIndicator;
private ViewPager mViewPager;
private FragmentPagerAdapter mAdapter;
private TabFragment[] mFragments = new TabFragment[mTitles.length];
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
initViews();
initDatas();
initEvents();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment