top of page
Search
  • ugcolgearstotosca

Nunca Te Des Por Vencido Libro Pdf 101







.Q: ViewPager onTabSelected not called after user swiped in code I have a ViewPager with 3 tabs and each of them has a ListView. I'm using ViewPager with PagerTabStrip as described in this tutorial: The user can swipe the tabs like shown in the video. This works perfectly. Now I would like the user to be able to click on a ListView item and call the Activity directly, without using the PagerTabStrip. To achieve that, I'm trying to set the OnTabSelectedListener to the tab's ViewPager, but it doesn't get called. What am I doing wrong? TabLayout tabLayout = (TabLayout) findViewById(R.id.tabs); tabLayout.setupWithViewPager(viewPager); tabLayout.setOnTabSelectedListener(new TabLayout.OnTabSelectedListener() { @Override public void onTabSelected(TabLayout.Tab tab) { Log.d("tag", "selected tab " + tab.getPosition()); } @Override public void onTabUnselected(TabLayout.Tab tab) { Log.d("tag", "unselected tab " + tab.getPosition()); } @Override public void onTabReselected(TabLayout.Tab tab) { Log.d("tag", "reselected tab " + tab.getPosition()); } }); Update I made some more tests and I'm almost sure that this is not a real problem. I've even managed to get the OnTabReselectedListener to be called, so I'm pretty sure that the problem is somewhere else. I'm not sure why, but somehow the be359ba680


Related links:

1 view0 comments

Recent Posts

See All
bottom of page