mirror of
https://github.com/gedoor/legado.git
synced 2024-07-06 23:47:49 +08:00
优化
This commit is contained in:
parent
cc53f7d0c5
commit
ce87726206
@ -1,12 +1,16 @@
|
||||
package io.legado.app.ui.book.read.page.provider
|
||||
|
||||
import io.legado.app.R
|
||||
import io.legado.app.model.ReadBook
|
||||
import io.legado.app.ui.book.read.page.api.DataSource
|
||||
import io.legado.app.ui.book.read.page.api.PageFactory
|
||||
import io.legado.app.ui.book.read.page.entities.TextPage
|
||||
import splitties.init.appCtx
|
||||
|
||||
class TextPageFactory(dataSource: DataSource) : PageFactory<TextPage>(dataSource) {
|
||||
|
||||
private val keepSwipeTip = appCtx.getString(R.string.keep_swipe_tip)
|
||||
|
||||
override fun hasPrev(): Boolean = with(dataSource) {
|
||||
return hasPrevChapter() || pageIndex > 0
|
||||
}
|
||||
@ -148,7 +152,7 @@ class TextPageFactory(dataSource: DataSource) : PageFactory<TextPage>(dataSource
|
||||
?: TextPage(title = nc.title).format()
|
||||
}
|
||||
return@with nc.getPage(1)?.removePageAloudSpan()
|
||||
?: TextPage(text = "继续滑动以加载下一章…").format()
|
||||
?: TextPage(text = keepSwipeTip).format()
|
||||
}
|
||||
}
|
||||
return TextPage().format()
|
||||
|
@ -1145,4 +1145,5 @@
|
||||
<string name="record_heap_dump_s">当应用发生OOM崩溃时保存堆转储</string>
|
||||
<string name="record_heap_dump_t">记录堆转储</string>
|
||||
<string name="font_weight_text">中/粗/细</string>
|
||||
<string name="keep_swipe_tip">继续滑动以加载下一章…</string>
|
||||
</resources>
|
||||
|
@ -1148,4 +1148,5 @@
|
||||
<string name="record_heap_dump_s">当应用发生OOM崩溃时保存堆转储</string>
|
||||
<string name="record_heap_dump_t">记录堆转储</string>
|
||||
<string name="font_weight_text">中/粗/细</string>
|
||||
<string name="keep_swipe_tip">继续滑动以加载下一章…</string>
|
||||
</resources>
|
||||
|
@ -1148,4 +1148,5 @@
|
||||
<string name="record_heap_dump_s">当应用发生OOM崩溃时保存堆转储</string>
|
||||
<string name="record_heap_dump_t">记录堆转储</string>
|
||||
<string name="font_weight_text">中/粗/细</string>
|
||||
<string name="keep_swipe_tip">继续滑动以加载下一章…</string>
|
||||
</resources>
|
||||
|
@ -1144,4 +1144,5 @@ Còn </string>
|
||||
<string name="record_heap_dump_s">当应用发生OOM崩溃时保存堆转储</string>
|
||||
<string name="record_heap_dump_t">记录堆转储</string>
|
||||
<string name="font_weight_text">中/粗/细</string>
|
||||
<string name="keep_swipe_tip">继续滑动以加载下一章…</string>
|
||||
</resources>
|
||||
|
@ -1145,4 +1145,5 @@
|
||||
<string name="record_heap_dump_s">当应用发生OOM崩溃时保存堆转储</string>
|
||||
<string name="record_heap_dump_t">记录堆转储</string>
|
||||
<string name="font_weight_text">中/粗/细</string>
|
||||
<string name="keep_swipe_tip">继续滑动以加载下一章…</string>
|
||||
</resources>
|
||||
|
@ -1147,4 +1147,5 @@
|
||||
<string name="record_heap_dump_s">当应用发生OOM崩溃时保存堆转储</string>
|
||||
<string name="record_heap_dump_t">记录堆转储</string>
|
||||
<string name="font_weight_text">中/粗/细</string>
|
||||
<string name="keep_swipe_tip">继续滑动以加载下一章…</string>
|
||||
</resources>
|
||||
|
@ -1147,4 +1147,5 @@
|
||||
<string name="record_heap_dump_s">当应用发生OOM崩溃时保存堆转储</string>
|
||||
<string name="record_heap_dump_t">记录堆转储</string>
|
||||
<string name="font_weight_text">中/粗/细</string>
|
||||
<string name="keep_swipe_tip">继续滑动以加载下一章…</string>
|
||||
</resources>
|
||||
|
@ -1143,9 +1143,10 @@
|
||||
<string name="adjust_chapter_index">Adjust of chapter index</string>
|
||||
<string name="clear_webview_data_success">Cleared successfully, automatically restarts the application after 3 seconds</string>
|
||||
<string name="key_page_on_long_press">Press and hold the key to turn the page</string>
|
||||
<string name="save_log">保存日志</string>
|
||||
<string name="create_heap_dump">创建堆转储</string>
|
||||
<string name="record_heap_dump_s">当应用发生OOM崩溃时保存堆转储</string>
|
||||
<string name="record_heap_dump_t">记录堆转储</string>
|
||||
<string name="save_log">Save logs</string>
|
||||
<string name="create_heap_dump">Create heap dump</string>
|
||||
<string name="record_heap_dump_s">Saving a heap dump when the application crashes by OOM</string>
|
||||
<string name="record_heap_dump_t">Capture heap dump</string>
|
||||
<string name="font_weight_text">N/B/L</string>
|
||||
<string name="keep_swipe_tip">Keep swiping to load the next chapter…</string>
|
||||
</resources>
|
||||
|
Loading…
Reference in New Issue
Block a user