pull/1744/head
kunfei 3 years ago
parent ceda5ce9a6
commit bc4e2d3e35
  1. 5
      app/src/main/java/io/legado/app/model/BookCover.kt

@ -86,9 +86,9 @@ object BookCover {
loadOnlyWifi: Boolean = false loadOnlyWifi: Boolean = false
): RequestBuilder<Drawable> { ): RequestBuilder<Drawable> {
val loadBlur = ImageLoader.load(context, defaultDrawable) val loadBlur = ImageLoader.load(context, defaultDrawable)
.apply(RequestOptions.bitmapTransform(BlurTransformation(25))) .transform(BlurTransformation(25))
return if (AppConfig.useDefaultCover) { return if (AppConfig.useDefaultCover) {
loadBlur.centerCrop() loadBlur
} else { } else {
val options = RequestOptions().set(OkHttpModelLoader.loadOnlyWifiOption, loadOnlyWifi) val options = RequestOptions().set(OkHttpModelLoader.loadOnlyWifiOption, loadOnlyWifi)
ImageLoader.load(context, path) ImageLoader.load(context, path)
@ -96,7 +96,6 @@ object BookCover {
.transform(BlurTransformation(25)) .transform(BlurTransformation(25))
.transition(DrawableTransitionOptions.withCrossFade(1500)) .transition(DrawableTransitionOptions.withCrossFade(1500))
.thumbnail(loadBlur) .thumbnail(loadBlur)
.centerCrop()
} }
} }

Loading…
Cancel
Save