avoid recreating the content of tabs at swiping

This commit is contained in:
tibbi 2021-10-11 22:08:23 +02:00
parent d31060739e
commit 87d3cf6501

View File

@ -331,6 +331,7 @@ class MainActivity : SimpleActivity() {
private fun initFragments() {
main_view_pager.adapter = ViewPagerAdapter(this)
main_view_pager.offscreenPageLimit = 2
main_view_pager.currentItem = config.lastUsedViewPagerPage
main_view_pager.onPageChangeListener {
main_tabs_holder.getTabAt(it)?.select()