mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-26 12:23:58 +01:00
Minor update ui (#2964)
* Change offscreen limit to retain contributions screen * no message
This commit is contained in:
parent
cdf45ad7f6
commit
7a70eb55c6
1 changed files with 2 additions and 1 deletions
|
|
@ -79,7 +79,7 @@ public class MainActivity extends AuthenticatedActivity implements FragmentManag
|
|||
setSupportActionBar(toolbar);
|
||||
requestAuthToken();
|
||||
initDrawer();
|
||||
setTitle(getString(R.string.navigation_item_home)); // Should I create a new string variable with another name instead?
|
||||
setTitle(getString(R.string.contributions_fragment)); // Should I create a new string variable with another name instead?
|
||||
setUpPager();
|
||||
|
||||
if (savedInstanceState != null) {
|
||||
|
|
@ -96,6 +96,7 @@ public class MainActivity extends AuthenticatedActivity implements FragmentManag
|
|||
viewPager.setAdapter(new NavTabFragmentPagerAdapter(getSupportFragmentManager()));
|
||||
viewPager.setOffscreenPageLimit(4);
|
||||
tabLayout.setOnNavigationItemSelectedListener(item -> {
|
||||
setTitle(item.getTitle());
|
||||
viewPager.setCurrentItem(item.getOrder());
|
||||
return true;
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue