mirror of
https://github.com/gedoor/legado.git
synced 2025-08-10 00:52:30 +00:00
修改图片绘制
This commit is contained in:
@@ -31,7 +31,7 @@ object AppLog {
|
||||
}
|
||||
|
||||
fun putDebug(message: String?, throwable: Throwable? = null) {
|
||||
if (AppConfig.recordLog) {
|
||||
if (AppConfig.recordLog || BuildConfig.DEBUG) {
|
||||
put(message, throwable)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -193,7 +193,14 @@ data class Book(
|
||||
}
|
||||
|
||||
fun getUseReplaceRule(): Boolean {
|
||||
return config.useReplaceRule ?: AppConfig.replaceEnableDefault
|
||||
val useReplaceRule = config.useReplaceRule
|
||||
if (useReplaceRule != null) {
|
||||
return useReplaceRule
|
||||
}
|
||||
if (type == BookType.image) {
|
||||
return false
|
||||
}
|
||||
return AppConfig.replaceEnableDefault
|
||||
}
|
||||
|
||||
fun setReSegment(reSegment: Boolean) {
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package io.legado.app.help
|
||||
|
||||
import io.legado.app.constant.AppLog
|
||||
import io.legado.app.constant.AppPattern
|
||||
import io.legado.app.constant.EventBus
|
||||
import io.legado.app.data.appDb
|
||||
@@ -126,7 +127,7 @@ object BookHelp {
|
||||
).writeBytes(it)
|
||||
}
|
||||
} catch (e: Exception) {
|
||||
e.printOnDebug()
|
||||
AppLog.putDebug("${src}下载错误", e)
|
||||
} finally {
|
||||
downloadImages.remove(src)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user