Finish migration to moko resources

This commit is contained in:
Jobobby04
2023-12-23 22:40:54 -05:00
parent 82098460ff
commit 16d433973c
175 changed files with 2061 additions and 1946 deletions
@@ -1,6 +1,8 @@
package tachiyomi.domain.library.model
import tachiyomi.domain.R
import dev.icerock.moko.resources.StringResource
import tachiyomi.i18n.MR
import tachiyomi.i18n.sy.SYMR
object LibraryGroup {
@@ -10,13 +12,13 @@ object LibraryGroup {
const val BY_TRACK_STATUS = 3
const val UNGROUPED = 4
fun groupTypeStringRes(type: Int, hasCategories: Boolean = true): Int {
fun groupTypeStringRes(type: Int, hasCategories: Boolean = true): StringResource {
return when (type) {
BY_STATUS -> R.string.status
BY_SOURCE -> R.string.label_sources
BY_TRACK_STATUS -> R.string.tracking_status
UNGROUPED -> R.string.ungrouped
else -> if (hasCategories) R.string.categories else R.string.ungrouped
BY_STATUS -> MR.strings.status
BY_SOURCE -> MR.strings.label_sources
BY_TRACK_STATUS -> SYMR.strings.tracking_status
UNGROUPED -> SYMR.strings.ungrouped
else -> if (hasCategories) MR.strings.categories else SYMR.strings.ungrouped
}
}
}