e-ink模式不再固定背景

pull/346/head
gedoor 4 years ago
parent 95e7ce3479
commit 12ee46ec5c
  1. 15
      app/src/main/java/io/legado/app/help/ReadBookConfig.kt

@ -77,16 +77,11 @@ object ReadBookConfig {
val dm = resources.displayMetrics val dm = resources.displayMetrics
val width = dm.widthPixels val width = dm.widthPixels
val height = dm.heightPixels val height = dm.heightPixels
if (AppConfig.isEInkMode && !AppConfig.isNightTheme) { bg = durConfig.bgDrawable(width, height).apply {
bg = ColorDrawable(Color.WHITE) if (this is BitmapDrawable) {
bgMeanColor = Color.WHITE bgMeanColor = BitmapUtils.getMeanColor(bitmap)
} else { } else if (this is ColorDrawable) {
bg = durConfig.bgDrawable(width, height).apply { bgMeanColor = color
if (this is BitmapDrawable) {
bgMeanColor = BitmapUtils.getMeanColor(bitmap)
} else if (this is ColorDrawable) {
bgMeanColor = color
}
} }
} }
isScroll = pageAnim == 3 isScroll = pageAnim == 3

Loading…
Cancel
Save