From dc9c01338343ba7757efa39cd094e4aa13cd2b3d Mon Sep 17 00:00:00 2001 From: AllenTom Date: Tue, 5 Aug 2025 16:51:17 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E6=B6=88=E6=81=AF=E5=92=8CAI?= =?UTF-8?q?=E4=BB=A3=E7=90=86=E9=A1=B5=E9=9D=A2=E7=9A=84=E6=96=87=E6=9C=AC?= =?UTF-8?q?=E9=A2=9C=E8=89=B2=EF=BC=8C=E6=B3=A8=E9=87=8A=E6=8E=89=E9=83=A8?= =?UTF-8?q?=E5=88=86=E6=B6=88=E6=81=AF=E5=88=97=E8=A1=A8=E5=88=9D=E5=A7=8B?= =?UTF-8?q?=E5=8C=96=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../aiosman/ravenow/ui/index/tabs/ai/Agent.kt | 8 ++--- .../ui/index/tabs/message/MessageList.kt | 6 ++-- .../tabs/message/MessageListViewModel.kt | 32 +++++++++---------- 3 files changed, 23 insertions(+), 23 deletions(-) diff --git a/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/ai/Agent.kt b/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/ai/Agent.kt index d98010e..60a6020 100644 --- a/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/ai/Agent.kt +++ b/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/ai/Agent.kt @@ -133,7 +133,7 @@ fun Agent() { Text( text = stringResource(R.string.agent_mine), fontSize = 14.sp, - color = if (pagerState.currentPage == 0) AppColors.mainText else AppColors.checkedBackground, + color = if (pagerState.currentPage == 0) AppColors.checkedText else AppColors.text, modifier = Modifier .clip(RoundedCornerShape(8.dp)) .background(if (pagerState.currentPage == 0) AppColors.checkedBackground else AppColors.unCheckedBackground) @@ -157,7 +157,7 @@ fun Agent() { Text( text = stringResource(R.string.agent_hot), fontSize = 14.sp, - color = if (pagerState.currentPage == 1) AppColors.mainText else AppColors.checkedBackground, + color = if (pagerState.currentPage == 1) AppColors.checkedText else AppColors.text, modifier = Modifier .clip(RoundedCornerShape(8.dp)) .background(if (pagerState.currentPage == 1) AppColors.checkedBackground else AppColors.unCheckedBackground) @@ -181,7 +181,7 @@ fun Agent() { Text( text = stringResource(R.string.agent_recommend), fontSize = 14.sp, - color = if (pagerState.currentPage == 2) AppColors.mainText else AppColors.checkedBackground, + color = if (pagerState.currentPage == 2) AppColors.checkedText else AppColors.text, modifier = Modifier .clip(RoundedCornerShape(8.dp)) .background(if (pagerState.currentPage == 2) AppColors.checkedBackground else AppColors.unCheckedBackground) @@ -205,7 +205,7 @@ fun Agent() { Text( text = stringResource(R.string.agent_other), fontSize = 14.sp, - color = if (pagerState.currentPage == 3) AppColors.mainText else AppColors.checkedBackground, + color = if (pagerState.currentPage == 3) AppColors.checkedText else AppColors.text, modifier = Modifier .clip(RoundedCornerShape(8.dp)) .background(if (pagerState.currentPage == 3) AppColors.checkedBackground else AppColors.unCheckedBackground) diff --git a/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/message/MessageList.kt b/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/message/MessageList.kt index 8fe00bb..1313475 100644 --- a/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/message/MessageList.kt +++ b/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/message/MessageList.kt @@ -198,7 +198,7 @@ fun NotificationsScreen() { Text( text = stringResource(R.string.chat_ai), fontSize = 14.sp, - color = if (pagerState.currentPage == 0) AppColors.mainText else AppColors.checkedBackground, + color = if (pagerState.currentPage == 0) AppColors.checkedText else AppColors.text, modifier = Modifier .clip(RoundedCornerShape(8.dp)) .background(if (pagerState.currentPage == 0) AppColors.checkedBackground else AppColors.unCheckedBackground) @@ -220,7 +220,7 @@ fun NotificationsScreen() { androidx.compose.material.Text( text = stringResource(R.string.chat_group), fontSize = 14.sp, - color = if (pagerState.currentPage == 1) AppColors.mainText else AppColors.checkedBackground, + color = if (pagerState.currentPage == 1) AppColors.checkedText else AppColors.text, modifier = Modifier .clip(RoundedCornerShape(8.dp)) .background(if (pagerState.currentPage == 1) AppColors.checkedBackground else AppColors.unCheckedBackground) @@ -244,7 +244,7 @@ fun NotificationsScreen() { androidx.compose.material.Text( text = stringResource(R.string.chat_friend), fontSize = 14.sp, - color = if (pagerState.currentPage == 2) AppColors.mainText else AppColors.checkedBackground, + color = if (pagerState.currentPage == 2) AppColors.checkedText else AppColors.text, modifier = Modifier .clip(RoundedCornerShape(8.dp)) .background(if (pagerState.currentPage == 2) AppColors.checkedBackground else AppColors.unCheckedBackground) diff --git a/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/message/MessageListViewModel.kt b/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/message/MessageListViewModel.kt index de5c59e..a9bbcd8 100644 --- a/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/message/MessageListViewModel.kt +++ b/app/src/main/java/com/aiosman/ravenow/ui/index/tabs/message/MessageListViewModel.kt @@ -84,22 +84,22 @@ object MessageListViewModel : ViewModel() { var unReadConversationCount by mutableStateOf(0L) var isFirstLoad = true suspend fun initData(context: Context, force: Boolean = false, loadChat: Boolean = false) { - if (loadChat) { - loadChatList(context) - loadUnreadCount() - } - - if (!isFirstLoad && !force) { - return - } - if (force) { - isLoading = true - } - isFirstLoad = false - val info = accountService.getMyNoticeInfo() - noticeInfo = info - - isLoading = false +// if (loadChat) { +// loadChatList(context) +// loadUnreadCount() +// } +// +// if (!isFirstLoad && !force) { +// return +// } +// if (force) { +// isLoading = true +// } +// isFirstLoad = false +// val info = accountService.getMyNoticeInfo() +// noticeInfo = info +// +// isLoading = false }