Add NSFW filter & source search into Merge: Find in another source
This commit is contained in:
parent
b7062738ea
commit
1483b71cf0
2 changed files with 16 additions and 6 deletions
|
|
@ -68,14 +68,12 @@ import tachiyomi.presentation.core.components.FastScrollLazyColumn
|
|||
import tachiyomi.presentation.core.components.LabeledCheckbox
|
||||
import tachiyomi.presentation.core.components.material.SecondaryItemAlpha
|
||||
import tachiyomi.presentation.core.components.material.padding
|
||||
import tachiyomi.presentation.core.components.material.topSmallPaddingValues
|
||||
import tachiyomi.presentation.core.i18n.stringResource
|
||||
import tachiyomi.presentation.core.screens.EmptyScreen
|
||||
import tachiyomi.presentation.core.screens.LoadingScreen
|
||||
import tachiyomi.presentation.core.theme.header
|
||||
import tachiyomi.presentation.core.util.clearFocusOnSoftKeyboardHide
|
||||
import tachiyomi.presentation.core.util.isScrollingUp
|
||||
import tachiyomi.presentation.core.util.plus
|
||||
import tachiyomi.presentation.core.util.runOnEnterKeyPressed
|
||||
import tachiyomi.presentation.core.util.secondaryItemAlpha
|
||||
import tachiyomi.source.local.LocalSource
|
||||
|
|
@ -104,7 +102,9 @@ fun SourcesScreen(
|
|||
modifier = Modifier.padding(contentPadding),
|
||||
)
|
||||
// KMK -->
|
||||
else -> Column {
|
||||
else -> Column(
|
||||
modifier = Modifier.padding(contentPadding),
|
||||
) {
|
||||
AnimatedFloatingSearchBox(
|
||||
listState = lazyListState,
|
||||
searchQuery = state.searchQuery,
|
||||
|
|
@ -115,7 +115,6 @@ fun SourcesScreen(
|
|||
FastScrollLazyColumn(
|
||||
state = lazyListState,
|
||||
// KMK <--
|
||||
contentPadding = contentPadding + topSmallPaddingValues,
|
||||
) {
|
||||
items(
|
||||
items = state.items,
|
||||
|
|
|
|||
|
|
@ -70,7 +70,17 @@ fun Screen.sourcesTab(
|
|||
),
|
||||
)
|
||||
} else {
|
||||
persistentListOf()
|
||||
// Merge: find in another source
|
||||
persistentListOf(
|
||||
// KMK -->
|
||||
AppBar.Action(
|
||||
title = stringResource(MR.strings.action_toggle_nsfw_only),
|
||||
icon = Icons.Outlined._18UpRating,
|
||||
iconTint = if (state.nsfwOnly) MaterialTheme.colorScheme.error else LocalContentColor.current,
|
||||
onClick = { screenModel.toggleNsfwOnly() },
|
||||
),
|
||||
// KMK <--
|
||||
)
|
||||
},
|
||||
// SY <--
|
||||
content = { contentPadding, snackbarHostState ->
|
||||
|
|
@ -119,8 +129,9 @@ fun Screen.sourcesTab(
|
|||
onDismiss = screenModel::closeDialog,
|
||||
// KMK -->
|
||||
onClickSettings = {
|
||||
if (source.installedExtension !== null)
|
||||
if (source.installedExtension !== null) {
|
||||
navigator.push(ExtensionDetailsScreen(source.installedExtension!!.pkgName))
|
||||
}
|
||||
screenModel.closeDialog()
|
||||
},
|
||||
// KMK <--
|
||||
|
|
|
|||
Loading…
Reference in a new issue