mirror of
https://github.com/tachiyomiorg/tachiyomi.git
synced 2024-12-22 16:01:49 +01:00
AppThemePreference: Filter dynamic theme if it's not available (#8250)
This commit is contained in:
parent
d03cbbe0cd
commit
4b5f965cea
@ -45,6 +45,8 @@ import eu.kanade.presentation.components.DIVIDER_ALPHA
|
|||||||
import eu.kanade.presentation.components.MangaCover
|
import eu.kanade.presentation.components.MangaCover
|
||||||
import eu.kanade.presentation.theme.TachiyomiTheme
|
import eu.kanade.presentation.theme.TachiyomiTheme
|
||||||
import eu.kanade.presentation.util.secondaryItemAlpha
|
import eu.kanade.presentation.util.secondaryItemAlpha
|
||||||
|
import eu.kanade.tachiyomi.util.system.DeviceUtil
|
||||||
|
import eu.kanade.tachiyomi.util.system.isDynamicColorAvailable
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
internal fun AppThemePreferenceWidget(
|
internal fun AppThemePreferenceWidget(
|
||||||
@ -72,7 +74,8 @@ private fun AppThemesList(
|
|||||||
onItemClick: (AppTheme) -> Unit,
|
onItemClick: (AppTheme) -> Unit,
|
||||||
) {
|
) {
|
||||||
val appThemes = remember {
|
val appThemes = remember {
|
||||||
AppTheme.values().filter { it.titleResId != null }
|
AppTheme.values()
|
||||||
|
.filterNot { it.titleResId == null || (it == AppTheme.MONET && !DeviceUtil.isDynamicColorAvailable) }
|
||||||
}
|
}
|
||||||
LazyRow(
|
LazyRow(
|
||||||
modifier = Modifier
|
modifier = Modifier
|
||||||
|
Loading…
Reference in New Issue
Block a user