From 2b86596467d4cb7df101b1a574f90de1bd80e584 Mon Sep 17 00:00:00 2001 From: kunfei Date: Sat, 31 Aug 2019 11:07:46 +0800 Subject: [PATCH] up --- .../io/legado/app/ui/readbook/config/BgTextConfigDialog.kt | 4 ++-- app/src/main/res/layout/item_bg_image.xml | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/app/src/main/java/io/legado/app/ui/readbook/config/BgTextConfigDialog.kt b/app/src/main/java/io/legado/app/ui/readbook/config/BgTextConfigDialog.kt index 73da06e09..a12072c7e 100644 --- a/app/src/main/java/io/legado/app/ui/readbook/config/BgTextConfigDialog.kt +++ b/app/src/main/java/io/legado/app/ui/readbook/config/BgTextConfigDialog.kt @@ -138,8 +138,8 @@ class BgTextConfigDialog : DialogFragment() { with(holder.itemView) { ImageLoader.load(context, context.assets.open("bg/$item").readBytes()) .centerCrop() - .setAsFile(iv_bg) - tv_name.text = item + .setAsBitmap(iv_bg) + tv_name.text = item.substring(0, item.lastIndexOf(".")) } } diff --git a/app/src/main/res/layout/item_bg_image.xml b/app/src/main/res/layout/item_bg_image.xml index d8ed15e7a..57c74b182 100644 --- a/app/src/main/res/layout/item_bg_image.xml +++ b/app/src/main/res/layout/item_bg_image.xml @@ -1,8 +1,8 @@ \ No newline at end of file