/*
- * Copyright © 2016-2017 Soren Stoutner <soren@stoutner.com>.
+ * Copyright © 2016-2018 Soren Stoutner <soren@stoutner.com>.
*
* This file is part of Privacy Browser <https://www.stoutner.com/privacy-browser>.
*
setContentView(R.layout.guide_coordinatorlayout);
// We need to use `SupportActionBar` from `android.support.v7.app.ActionBar` until the minimum API is >= 21.
- Toolbar guideAppBar = (Toolbar) findViewById(R.id.guide_toolbar);
+ Toolbar guideAppBar = findViewById(R.id.guide_toolbar);
setSupportActionBar(guideAppBar);
// Display the home arrow on `ppBar`.
appBar.setDisplayHomeAsUpEnabled(true);
// Setup the ViewPager.
- ViewPager aboutViewPager = (ViewPager) findViewById(R.id.guide_viewpager);
+ ViewPager aboutViewPager = findViewById(R.id.guide_viewpager);
assert aboutViewPager != null; // This assert removes the incorrect warning in Android Studio on the following line that aboutViewPager might be null.
aboutViewPager.setAdapter(new guidePagerAdapter(getSupportFragmentManager()));
// Setup the TabLayout and connect it to the ViewPager.
- TabLayout aboutTabLayout = (TabLayout) findViewById(R.id.guide_tablayout);
+ TabLayout aboutTabLayout = findViewById(R.id.guide_tablayout);
assert aboutTabLayout != null; // This assert removes the incorrect warning in Android Studio on the following line that aboutTabLayout might be null.
aboutTabLayout.setupWithViewPager(aboutViewPager);
}
@Override
// Get the count of the number of tabs.
public int getCount() {
- return 7;
+ return 9;
}
@Override
return getString(R.string.domain_settings);
case 5:
- return getString(R.string.ssl_certificate_pinning);
+ return getString(R.string.ssl_certificates);
case 6:
return getString(R.string.tor);
case 7:
return getString(R.string.tracking_ids);
+ case 8:
+ return getString(R.string.bookmarks);
+
default:
return "";
}
return GuideTabFragment.createTab(tab);
}
}
-
}