mirror of
https://github.com/mihonapp/mihon.git
synced 2025-11-12 12:08:56 +01:00
Address more Compose lint warnings
This commit is contained in:
@@ -23,6 +23,7 @@ import eu.kanade.tachiyomi.ui.browse.migration.sources.migrateSourceTab
|
||||
import eu.kanade.tachiyomi.ui.browse.source.globalsearch.GlobalSearchScreen
|
||||
import eu.kanade.tachiyomi.ui.browse.source.sourcesTab
|
||||
import eu.kanade.tachiyomi.ui.main.MainActivity
|
||||
import kotlinx.collections.immutable.persistentListOf
|
||||
|
||||
data class BrowseTab(
|
||||
private val toExtensions: Boolean = false,
|
||||
@@ -54,7 +55,7 @@ data class BrowseTab(
|
||||
|
||||
TabbedScreen(
|
||||
titleRes = R.string.browse,
|
||||
tabs = listOf(
|
||||
tabs = persistentListOf(
|
||||
sourcesTab(),
|
||||
extensionsTab(extensionsScreenModel),
|
||||
migrateSourceTab(),
|
||||
|
||||
@@ -14,6 +14,7 @@ import eu.kanade.presentation.components.TabContent
|
||||
import eu.kanade.tachiyomi.R
|
||||
import eu.kanade.tachiyomi.extension.model.Extension
|
||||
import eu.kanade.tachiyomi.ui.browse.extension.details.ExtensionDetailsScreen
|
||||
import kotlinx.collections.immutable.persistentListOf
|
||||
|
||||
@Composable
|
||||
fun extensionsTab(
|
||||
@@ -26,7 +27,7 @@ fun extensionsTab(
|
||||
titleRes = R.string.label_extensions,
|
||||
badgeNumber = state.updates.takeIf { it > 0 },
|
||||
searchEnabled = true,
|
||||
actions = listOf(
|
||||
actions = persistentListOf(
|
||||
AppBar.Action(
|
||||
title = stringResource(R.string.action_filter),
|
||||
icon = Icons.Outlined.Translate,
|
||||
|
||||
@@ -17,6 +17,7 @@ import eu.kanade.presentation.components.AppBar
|
||||
import eu.kanade.presentation.components.TabContent
|
||||
import eu.kanade.tachiyomi.R
|
||||
import eu.kanade.tachiyomi.ui.browse.migration.manga.MigrateMangaScreen
|
||||
import kotlinx.collections.immutable.persistentListOf
|
||||
|
||||
@Composable
|
||||
fun Screen.migrateSourceTab(): TabContent {
|
||||
@@ -27,7 +28,7 @@ fun Screen.migrateSourceTab(): TabContent {
|
||||
|
||||
return TabContent(
|
||||
titleRes = R.string.label_migration,
|
||||
actions = listOf(
|
||||
actions = persistentListOf(
|
||||
AppBar.Action(
|
||||
title = stringResource(R.string.migration_help_guide),
|
||||
icon = Icons.AutoMirrored.Outlined.HelpOutline,
|
||||
|
||||
@@ -19,6 +19,7 @@ import eu.kanade.presentation.components.TabContent
|
||||
import eu.kanade.tachiyomi.R
|
||||
import eu.kanade.tachiyomi.ui.browse.source.browse.BrowseSourceScreen
|
||||
import eu.kanade.tachiyomi.ui.browse.source.globalsearch.GlobalSearchScreen
|
||||
import kotlinx.collections.immutable.persistentListOf
|
||||
import kotlinx.coroutines.flow.collectLatest
|
||||
import kotlinx.coroutines.launch
|
||||
|
||||
@@ -30,7 +31,7 @@ fun Screen.sourcesTab(): TabContent {
|
||||
|
||||
return TabContent(
|
||||
titleRes = R.string.label_sources,
|
||||
actions = listOf(
|
||||
actions = persistentListOf(
|
||||
AppBar.Action(
|
||||
title = stringResource(R.string.action_global_search),
|
||||
icon = Icons.Outlined.TravelExplore,
|
||||
|
||||
@@ -55,6 +55,7 @@ import eu.kanade.presentation.components.NestedMenuItem
|
||||
import eu.kanade.presentation.util.Screen
|
||||
import eu.kanade.tachiyomi.R
|
||||
import eu.kanade.tachiyomi.databinding.DownloadListBinding
|
||||
import kotlinx.collections.immutable.persistentListOf
|
||||
import tachiyomi.core.util.lang.launchUI
|
||||
import tachiyomi.presentation.core.components.Pill
|
||||
import tachiyomi.presentation.core.components.material.ExtendedFloatingActionButton
|
||||
@@ -183,7 +184,7 @@ object DownloadQueueScreen : Screen() {
|
||||
}
|
||||
|
||||
AppBarActions(
|
||||
listOf(
|
||||
persistentListOf(
|
||||
AppBar.Action(
|
||||
title = stringResource(R.string.action_sort),
|
||||
icon = Icons.AutoMirrored.Outlined.Sort,
|
||||
|
||||
Reference in New Issue
Block a user