pull/1771/head
gedoor 3 years ago
parent 0050be8f2e
commit 8bfb4ac3d5
  1. 1
      app/build.gradle
  2. 2
      app/src/main/java/io/legado/app/help/config/AppConfig.kt
  3. 8
      app/src/main/java/io/legado/app/ui/book/explore/ExploreShowAdapter.kt
  4. 2
      app/src/main/java/io/legado/app/ui/book/search/SearchAdapter.kt

@ -157,6 +157,7 @@ dependencies {
implementation('androidx.viewpager2:viewpager2:1.0.0') implementation('androidx.viewpager2:viewpager2:1.0.0')
implementation('androidx.webkit:webkit:1.4.0') implementation('androidx.webkit:webkit:1.4.0')
//google
implementation('com.google.android.material:material:1.5.0') implementation('com.google.android.material:material:1.5.0')
implementation('com.google.android.flexbox:flexbox:3.0.0') implementation('com.google.android.flexbox:flexbox:3.0.0')
implementation('com.google.code.gson:gson:2.9.0') implementation('com.google.code.gson:gson:2.9.0')

@ -304,7 +304,7 @@ object AppConfig : SharedPreferences.OnSharedPreferenceChangeListener {
val recordLog get() = appCtx.getPrefBoolean(PreferKey.recordLog) val recordLog get() = appCtx.getPrefBoolean(PreferKey.recordLog)
val loadOnlyWifi = appCtx.getPrefBoolean(PreferKey.loadCoverOnlyWifi, false) val loadCoverOnlyWifi = appCtx.getPrefBoolean(PreferKey.loadCoverOnlyWifi, false)
val doublePageHorizontal: Boolean val doublePageHorizontal: Boolean
get() = appCtx.getPrefBoolean(PreferKey.doublePageHorizontal, true) get() = appCtx.getPrefBoolean(PreferKey.doublePageHorizontal, true)

@ -43,7 +43,13 @@ class ExploreShowAdapter(context: Context, val callBack: CallBack) :
llKind.visible() llKind.visible()
llKind.setLabels(kinds) llKind.setLabels(kinds)
} }
ivCover.load(item.coverUrl, item.name, item.author, AppConfig.loadOnlyWifi, item.origin) ivCover.load(
item.coverUrl,
item.name,
item.author,
AppConfig.loadCoverOnlyWifi,
item.origin
)
} }
} }

@ -86,7 +86,7 @@ class SearchAdapter(context: Context, val callBack: CallBack) :
searchBook.coverUrl, searchBook.coverUrl,
searchBook.name, searchBook.name,
searchBook.author, searchBook.author,
AppConfig.loadOnlyWifi, AppConfig.loadCoverOnlyWifi,
searchBook.origin searchBook.origin
) )
} }

Loading…
Cancel
Save