Replace remaining Android-specific strings
Also renaming the helper composables so it's a bit easier to find/replace everything in forks.
This commit is contained in:
@@ -38,7 +38,7 @@ import tachiyomi.presentation.core.components.LabeledCheckbox
|
||||
import tachiyomi.presentation.core.components.RadioItem
|
||||
import tachiyomi.presentation.core.components.SortItem
|
||||
import tachiyomi.presentation.core.components.TriStateItem
|
||||
import tachiyomi.presentation.core.i18n.localize
|
||||
import tachiyomi.presentation.core.i18n.stringResource
|
||||
import tachiyomi.presentation.core.theme.active
|
||||
|
||||
@Composable
|
||||
@@ -66,20 +66,20 @@ fun ChapterSettingsDialog(
|
||||
TabbedDialog(
|
||||
onDismissRequest = onDismissRequest,
|
||||
tabTitles = persistentListOf(
|
||||
localize(MR.strings.action_filter),
|
||||
localize(MR.strings.action_sort),
|
||||
localize(MR.strings.action_display),
|
||||
stringResource(MR.strings.action_filter),
|
||||
stringResource(MR.strings.action_sort),
|
||||
stringResource(MR.strings.action_display),
|
||||
),
|
||||
tabOverflowMenuContent = { closeMenu ->
|
||||
DropdownMenuItem(
|
||||
text = { Text(localize(MR.strings.set_chapter_settings_as_default)) },
|
||||
text = { Text(stringResource(MR.strings.set_chapter_settings_as_default)) },
|
||||
onClick = {
|
||||
showSetAsDefaultDialog = true
|
||||
closeMenu()
|
||||
},
|
||||
)
|
||||
DropdownMenuItem(
|
||||
text = { Text(localize(MR.strings.action_reset)) },
|
||||
text = { Text(stringResource(MR.strings.action_reset)) },
|
||||
onClick = {
|
||||
onResetToDefault()
|
||||
closeMenu()
|
||||
@@ -136,17 +136,17 @@ private fun ColumnScope.FilterPage(
|
||||
onScanlatorFilterClicked: (() -> Unit),
|
||||
) {
|
||||
TriStateItem(
|
||||
label = localize(MR.strings.label_downloaded),
|
||||
label = stringResource(MR.strings.label_downloaded),
|
||||
state = downloadFilter,
|
||||
onClick = onDownloadFilterChanged,
|
||||
)
|
||||
TriStateItem(
|
||||
label = localize(MR.strings.action_filter_unread),
|
||||
label = stringResource(MR.strings.action_filter_unread),
|
||||
state = unreadFilter,
|
||||
onClick = onUnreadFilterChanged,
|
||||
)
|
||||
TriStateItem(
|
||||
label = localize(MR.strings.action_filter_bookmarked),
|
||||
label = stringResource(MR.strings.action_filter_bookmarked),
|
||||
state = bookmarkedFilter,
|
||||
onClick = onBookmarkedFilterChanged,
|
||||
)
|
||||
@@ -179,7 +179,7 @@ fun ScanlatorFilterItem(
|
||||
},
|
||||
)
|
||||
Text(
|
||||
text = localize(MR.strings.scanlator),
|
||||
text = stringResource(MR.strings.scanlator),
|
||||
style = MaterialTheme.typography.bodyMedium,
|
||||
)
|
||||
}
|
||||
@@ -198,7 +198,7 @@ private fun ColumnScope.SortPage(
|
||||
MR.strings.action_sort_alpha to Manga.CHAPTER_SORTING_ALPHABET,
|
||||
).map { (titleRes, mode) ->
|
||||
SortItem(
|
||||
label = localize(titleRes),
|
||||
label = stringResource(titleRes),
|
||||
sortDescending = sortDescending.takeIf { sortingMode == mode },
|
||||
onClick = { onItemSelected(mode) },
|
||||
)
|
||||
@@ -215,7 +215,7 @@ private fun ColumnScope.DisplayPage(
|
||||
MR.strings.show_chapter_number to Manga.CHAPTER_DISPLAY_NUMBER,
|
||||
).map { (titleRes, mode) ->
|
||||
RadioItem(
|
||||
label = localize(titleRes),
|
||||
label = stringResource(titleRes),
|
||||
selected = displayMode == mode,
|
||||
onClick = { onItemSelected(mode) },
|
||||
)
|
||||
@@ -231,15 +231,15 @@ private fun SetAsDefaultDialog(
|
||||
|
||||
AlertDialog(
|
||||
onDismissRequest = onDismissRequest,
|
||||
title = { Text(text = localize(MR.strings.chapter_settings)) },
|
||||
title = { Text(text = stringResource(MR.strings.chapter_settings)) },
|
||||
text = {
|
||||
Column(
|
||||
verticalArrangement = Arrangement.spacedBy(12.dp),
|
||||
) {
|
||||
Text(text = localize(MR.strings.confirm_set_chapter_settings))
|
||||
Text(text = stringResource(MR.strings.confirm_set_chapter_settings))
|
||||
|
||||
LabeledCheckbox(
|
||||
label = localize(MR.strings.also_set_chapter_settings_for_library),
|
||||
label = stringResource(MR.strings.also_set_chapter_settings_for_library),
|
||||
checked = optionalChecked,
|
||||
onCheckedChange = { optionalChecked = it },
|
||||
)
|
||||
@@ -247,7 +247,7 @@ private fun SetAsDefaultDialog(
|
||||
},
|
||||
dismissButton = {
|
||||
TextButton(onClick = onDismissRequest) {
|
||||
Text(text = localize(MR.strings.action_cancel))
|
||||
Text(text = stringResource(MR.strings.action_cancel))
|
||||
}
|
||||
},
|
||||
confirmButton = {
|
||||
@@ -257,7 +257,7 @@ private fun SetAsDefaultDialog(
|
||||
onDismissRequest()
|
||||
},
|
||||
) {
|
||||
Text(text = localize(MR.strings.action_ok))
|
||||
Text(text = stringResource(MR.strings.action_ok))
|
||||
}
|
||||
},
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user