优化书籍目录页tabs效果

pull/67/head
Administrator 5 years ago
parent 75cac24f22
commit f7d0a4748d
  1. 1
      app/src/main/java/io/legado/app/ui/chapterlist/ChapterListActivity.kt
  2. 3
      app/src/main/res/layout/view_tab_layout.xml

@ -25,6 +25,7 @@ class ChapterListActivity : VMBaseActivity<ChapterListViewModel>(R.layout.activi
private var searchView: SearchView? = null
override fun onActivityCreated(savedInstanceState: Bundle?) {
tab_layout.isTabIndicatorFullWidth = false
tab_layout.setSelectedTabIndicatorColor(accentColor)
viewModel.bookUrl = intent.getStringExtra("bookUrl")
viewModel.loadBook {

@ -1,6 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<com.google.android.material.tabs.TabLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/tab_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:tabBackground="@android:color/transparent"
app:tabRippleColor="@android:color/transparent"
android:theme="?attr/actionBarStyle" />
Loading…
Cancel
Save