Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -153,6 +153,7 @@ data class RssSource(
|
||||
style = doc.readString("$.style"),
|
||||
enableJs = doc.readBool("$.enableJs") ?: true,
|
||||
loadWithBaseUrl = doc.readBool("$.loadWithBaseUrl") ?: true,
|
||||
enabledCookieJar = doc.readBool("$.enabledCookieJar") ?: false,
|
||||
customOrder = doc.readInt("$.customOrder") ?: 0
|
||||
)
|
||||
}
|
||||
|
||||
@@ -150,6 +150,7 @@ object SourceAnalyzer {
|
||||
source.customOrder = sourceAny.customOrder
|
||||
source.enabled = sourceAny.enabled
|
||||
source.enabledExplore = sourceAny.enabledExplore
|
||||
source.enabledCookieJar = sourceAny.enabledCookieJar
|
||||
source.concurrentRate = sourceAny.concurrentRate
|
||||
source.header = sourceAny.header
|
||||
source.loginUrl = when (sourceAny.loginUrl) {
|
||||
@@ -219,6 +220,7 @@ object SourceAnalyzer {
|
||||
var customOrder: Int = 0, // 手动排序编号
|
||||
var enabled: Boolean = true, // 是否启用
|
||||
var enabledExplore: Boolean = true, // 启用发现
|
||||
var enabledCookieJar: Boolean = false, // 启用CookieJar
|
||||
var concurrentRate: String? = null, // 并发率
|
||||
var header: String? = null, // 请求头
|
||||
var loginUrl: Any? = null, // 登录规则
|
||||
|
||||
@@ -229,8 +229,12 @@ abstract class BaseReadBookActivity :
|
||||
customView { alertBinding.root }
|
||||
yesButton {
|
||||
alertBinding.run {
|
||||
val start = editStart.text?.toString()?.toInt() ?: 0
|
||||
val end = editEnd.text?.toString()?.toInt() ?: book.totalChapterNum
|
||||
val start = editStart.text!!.toString().let {
|
||||
if (it.isEmpty()) 0 else it.toInt()
|
||||
}
|
||||
val end = editEnd.text!!.toString().let {
|
||||
if (it.isEmpty()) book.totalChapterNum else it.toInt()
|
||||
}
|
||||
CacheBook.start(this@BaseReadBookActivity, book, start - 1, end - 1)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user