mirror of
https://github.com/null2264/yokai.git
synced 2025-06-21 10:44:42 +00:00
chore: Use "Page x of y" instead of "x pages left"
This commit is contained in:
parent
38db95b6de
commit
942ca851d5
4 changed files with 8 additions and 19 deletions
|
@ -55,19 +55,12 @@ class ChapterHolder(
|
||||||
|
|
||||||
val showPagesLeft = !chapter.read && chapter.last_page_read > 0 && !isLocked
|
val showPagesLeft = !chapter.read && chapter.last_page_read > 0 && !isLocked
|
||||||
|
|
||||||
if (showPagesLeft && chapter.pages_left > 0) {
|
if (showPagesLeft) {
|
||||||
statuses.add(
|
statuses.add(
|
||||||
itemView.context.getString(
|
itemView.context.getString(
|
||||||
MR.plurals.pages_left,
|
MR.strings.page_x_of_y,
|
||||||
chapter.pages_left,
|
|
||||||
chapter.pages_left,
|
|
||||||
),
|
|
||||||
)
|
|
||||||
} else if (showPagesLeft) {
|
|
||||||
statuses.add(
|
|
||||||
itemView.context.getString(
|
|
||||||
MR.strings.page_,
|
|
||||||
chapter.last_page_read + 1,
|
chapter.last_page_read + 1,
|
||||||
|
chapter.pages_left + chapter.last_page_read,
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
|
@ -203,11 +203,11 @@ class RecentMangaHolder(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
item.chapter.id != item.mch.chapter.id -> readLastText(!moreVisible)
|
item.chapter.id != item.mch.chapter.id -> readLastText(!moreVisible)
|
||||||
item.chapter.pages_left > 0 && !item.chapter.read -> context.timeSpanFromNow(MR.strings.read_, item.mch.history.last_read) +
|
item.chapter.last_page_read > 0 && !item.chapter.read -> context.timeSpanFromNow(MR.strings.read_, item.mch.history.last_read) +
|
||||||
"\n" + itemView.context.getString(
|
"\n" + itemView.context.getString(
|
||||||
MR.plurals.pages_left,
|
MR.strings.page_x_of_y,
|
||||||
item.chapter.pages_left,
|
item.chapter.last_page_read + 1,
|
||||||
item.chapter.pages_left,
|
item.chapter.pages_left + item.chapter.last_page_read,
|
||||||
)
|
)
|
||||||
else -> context.timeSpanFromNow(MR.strings.read_, item.mch.history.last_read)
|
else -> context.timeSpanFromNow(MR.strings.read_, item.mch.history.last_read)
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,11 +10,6 @@
|
||||||
<item quantity="other">%1$s chapters</item>
|
<item quantity="other">%1$s chapters</item>
|
||||||
</plurals>
|
</plurals>
|
||||||
|
|
||||||
<plurals name="pages_left">
|
|
||||||
<item quantity="one">%1$d page left</item>
|
|
||||||
<item quantity="other">%1$d pages left</item>
|
|
||||||
</plurals>
|
|
||||||
|
|
||||||
<plurals name="category_plural">
|
<plurals name="category_plural">
|
||||||
<item quantity="one">%d category</item>
|
<item quantity="one">%d category</item>
|
||||||
<item quantity="other">%d categories</item>
|
<item quantity="other">%d categories</item>
|
||||||
|
|
|
@ -72,6 +72,7 @@
|
||||||
<string name="last_read_chapter_">Last read Chapter %1$s</string>
|
<string name="last_read_chapter_">Last read Chapter %1$s</string>
|
||||||
<string name="chapter_">Chapter %1$s</string>
|
<string name="chapter_">Chapter %1$s</string>
|
||||||
<string name="chapter_x_of_y">Chapter %1$d of %2$d</string>
|
<string name="chapter_x_of_y">Chapter %1$d of %2$d</string>
|
||||||
|
<string name="page_x_of_y">Page %1$d of %2$d</string>
|
||||||
<string name="all_chapters_read">All chapters read</string>
|
<string name="all_chapters_read">All chapters read</string>
|
||||||
<string name="bookmarked">Bookmarked</string>
|
<string name="bookmarked">Bookmarked</string>
|
||||||
<string name="not_bookmarked">Not bookmarked</string>
|
<string name="not_bookmarked">Not bookmarked</string>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue