From 5bbf849509820ca2852b0d1d296bb415771e2f42 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolf-Martell=20Montw=C3=A9?= Date: Wed, 8 Nov 2023 11:34:49 +0100 Subject: [PATCH] Change expanded to saveable state --- .../setup/ui/autodiscovery/view/AutoDiscoveryResultView.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/feature/account/setup/src/main/kotlin/app/k9mail/feature/account/setup/ui/autodiscovery/view/AutoDiscoveryResultView.kt b/feature/account/setup/src/main/kotlin/app/k9mail/feature/account/setup/ui/autodiscovery/view/AutoDiscoveryResultView.kt index 753afa8b8..3ab9667b9 100644 --- a/feature/account/setup/src/main/kotlin/app/k9mail/feature/account/setup/ui/autodiscovery/view/AutoDiscoveryResultView.kt +++ b/feature/account/setup/src/main/kotlin/app/k9mail/feature/account/setup/ui/autodiscovery/view/AutoDiscoveryResultView.kt @@ -7,7 +7,7 @@ import androidx.compose.foundation.layout.Column import androidx.compose.foundation.layout.padding import androidx.compose.runtime.Composable import androidx.compose.runtime.mutableStateOf -import androidx.compose.runtime.remember +import androidx.compose.runtime.saveable.rememberSaveable import androidx.compose.ui.Modifier import androidx.compose.ui.graphics.Color import androidx.compose.ui.tooling.preview.Preview @@ -29,7 +29,7 @@ internal fun AutoDiscoveryResultView( onEditConfigurationClick: () -> Unit, modifier: Modifier = Modifier, ) { - val expanded = remember { + val expanded = rememberSaveable { mutableStateOf(settings?.isTrusted?.not() ?: false) }