From e5c63c1c70a00b30a651cb01c758d3dbfc2e785b Mon Sep 17 00:00:00 2001 From: Mystery0 Date: Sat, 30 Mar 2024 22:28:34 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BB=A3=E7=A0=81=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/vip/mystery0/xhu/timetable/model/UserInfo.kt | 6 +++--- .../vip/mystery0/xhu/timetable/ui/activity/LoginActivity.kt | 2 -- .../mystery0/xhu/timetable/ui/activity/PagerTodayCourse.kt | 1 - 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/app/src/main/java/vip/mystery0/xhu/timetable/model/UserInfo.kt b/app/src/main/java/vip/mystery0/xhu/timetable/model/UserInfo.kt index 8943b556..022284cb 100644 --- a/app/src/main/java/vip/mystery0/xhu/timetable/model/UserInfo.kt +++ b/app/src/main/java/vip/mystery0/xhu/timetable/model/UserInfo.kt @@ -28,9 +28,9 @@ enum class Gender(val showTitle: String) { companion object { fun parseOld(sex: String): Gender = when (sex) { - "男" -> Gender.MALE - "女" -> Gender.FEMALE - else -> Gender.UNKNOWN + "男" -> MALE + "女" -> FEMALE + else -> UNKNOWN } } } diff --git a/app/src/main/java/vip/mystery0/xhu/timetable/ui/activity/LoginActivity.kt b/app/src/main/java/vip/mystery0/xhu/timetable/ui/activity/LoginActivity.kt index def02ed2..cccb7424 100644 --- a/app/src/main/java/vip/mystery0/xhu/timetable/ui/activity/LoginActivity.kt +++ b/app/src/main/java/vip/mystery0/xhu/timetable/ui/activity/LoginActivity.kt @@ -27,7 +27,6 @@ import androidx.compose.runtime.getValue import androidx.compose.runtime.mutableStateOf import androidx.compose.runtime.remember import androidx.compose.runtime.setValue -import androidx.compose.ui.ExperimentalComposeUiApi import androidx.compose.ui.Modifier import androidx.compose.ui.focus.FocusRequester import androidx.compose.ui.focus.focusRequester @@ -53,7 +52,6 @@ import vip.mystery0.xhu.timetable.viewmodel.LoginViewModel class LoginActivity : BaseComposeActivity() { private val viewModel: LoginViewModel by viewModels() - @OptIn(ExperimentalComposeUiApi::class) @Composable override fun BuildContent() { val keyboardController = LocalSoftwareKeyboardController.current diff --git a/app/src/main/java/vip/mystery0/xhu/timetable/ui/activity/PagerTodayCourse.kt b/app/src/main/java/vip/mystery0/xhu/timetable/ui/activity/PagerTodayCourse.kt index 1399e7fe..d668e717 100644 --- a/app/src/main/java/vip/mystery0/xhu/timetable/ui/activity/PagerTodayCourse.kt +++ b/app/src/main/java/vip/mystery0/xhu/timetable/ui/activity/PagerTodayCourse.kt @@ -233,7 +233,6 @@ private fun DrawLine() { ) } -@OptIn(ExperimentalMaterial3Api::class) @ExperimentalMaterialApi @Composable private fun DrawPoemsCard(