parent
d53bf5a8e1
commit
884218b50c
|
|
@ -15,6 +15,7 @@ import androidx.compose.material.icons.outlined.SecurityUpdateWarning
|
|||
import androidx.compose.material.icons.outlined.SpeakerNotesOff
|
||||
import androidx.compose.material.icons.outlined.StarOutline
|
||||
import androidx.compose.material.icons.outlined.Verified
|
||||
import androidx.compose.material.icons.rounded.Sort
|
||||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.ui.ExperimentalComposeUiApi
|
||||
import androidx.compose.ui.Modifier
|
||||
|
|
@ -225,6 +226,24 @@ fun HabitSettingsPage(
|
|||
summaryOff = stringResource(id = R.string.tip_collect_thread_see_lz)
|
||||
)
|
||||
}
|
||||
prefsItem {
|
||||
SwitchPref(
|
||||
key = "collect_thread_desc_sort",
|
||||
title = stringResource(id = R.string.settings_collect_thread_desc_sort),
|
||||
defaultChecked = false,
|
||||
leadingIcon = {
|
||||
LeadingIcon {
|
||||
AvatarIcon(
|
||||
icon = Icons.Rounded.Sort,
|
||||
size = Sizes.Small,
|
||||
contentDescription = null,
|
||||
)
|
||||
}
|
||||
},
|
||||
summaryOn = stringResource(id = R.string.tip_collect_thread_desc_sort_on),
|
||||
summaryOff = stringResource(id = R.string.tip_collect_thread_desc_sort)
|
||||
)
|
||||
}
|
||||
prefsItem {
|
||||
SwitchPref(
|
||||
key = "show_both_username_and_nickname",
|
||||
|
|
|
|||
|
|
@ -52,6 +52,7 @@ import com.huanchengfly.tieba.post.ui.common.theme.compose.pullRefreshIndicator
|
|||
import com.huanchengfly.tieba.post.ui.page.destinations.ThreadPageDestination
|
||||
import com.huanchengfly.tieba.post.ui.page.thread.ThreadPageFrom
|
||||
import com.huanchengfly.tieba.post.ui.page.thread.ThreadPageFromStoreExtra
|
||||
import com.huanchengfly.tieba.post.ui.page.thread.ThreadSortType
|
||||
import com.huanchengfly.tieba.post.ui.widgets.compose.Avatar
|
||||
import com.huanchengfly.tieba.post.ui.widgets.compose.BackNavigationIcon
|
||||
import com.huanchengfly.tieba.post.ui.widgets.compose.ErrorScreen
|
||||
|
|
@ -195,6 +196,7 @@ fun ThreadStorePage(
|
|||
threadId = info.threadId.toLong(),
|
||||
postId = info.markPid.toLong(),
|
||||
seeLz = context.appPreferences.collectThreadSeeLz,
|
||||
sortType = if(context.appPreferences.collectThreadDescSort) ThreadSortType.SORT_TYPE_DESC else ThreadSortType.SORT_TYPE_DEFAULT,
|
||||
from = ThreadPageFrom.FROM_STORE,
|
||||
extra = ThreadPageFromStoreExtra(
|
||||
maxPid = info.maxPid.toLong(),
|
||||
|
|
|
|||
|
|
@ -77,6 +77,11 @@ open class AppPreferencesUtils private constructor(ctx: Context) {
|
|||
key = "collect_thread_see_lz"
|
||||
)
|
||||
|
||||
var collectThreadDescSort by DataStoreDelegates.boolean(
|
||||
defaultValue = false,
|
||||
key = "collect_thread_desc_sort"
|
||||
)
|
||||
|
||||
var customPrimaryColor by DataStoreDelegates.string(key = "custom_primary_color")
|
||||
|
||||
var customStatusBarFontDark by DataStoreDelegates.boolean(
|
||||
|
|
|
|||
|
|
@ -259,6 +259,9 @@
|
|||
<string name="settings_collect_thread_see_lz">收藏贴自动开启只看楼主</string>
|
||||
<string name="tip_collect_thread_see_lz">开启后,从收藏进入的贴子将自动切换至只看楼主</string>
|
||||
<string name="tip_collect_thread_see_lz_on">从收藏进入的贴子将自动切换至只看楼主</string>
|
||||
<string name="settings_collect_thread_desc_sort">收藏贴自动开启倒序浏览</string>
|
||||
<string name="tip_collect_thread_desc_sort">开启后,从收藏进入的贴子将自动切换至倒序浏览</string>
|
||||
<string name="tip_collect_thread_desc_sort_on">从收藏进入的贴子将自动切换至倒序浏览</string>
|
||||
<string name="toast_feed_refresh">更新了 %1$d 条动态</string>
|
||||
<string name="button_submit_dislike">不感兴趣</string>
|
||||
<string name="title_dislike">不喜欢推荐用户的理由</string>
|
||||
|
|
|
|||
Loading…
Reference in New Issue