@@ -10,14 +10,19 @@ import androidx.compose.foundation.layout.fillMaxWidth
1010import androidx.compose.foundation.layout.height
1111import androidx.compose.foundation.layout.offset
1212import androidx.compose.foundation.shape.RoundedCornerShape
13+ import androidx.compose.foundation.layout.Arrangement
14+ import androidx.compose.foundation.layout.padding
1315import androidx.compose.material.ExperimentalMaterialApi
1416import androidx.compose.material3.ButtonDefaults
1517import androidx.compose.material3.Checkbox
1618import androidx.compose.material3.ExperimentalMaterial3Api
1719import androidx.compose.material3.MaterialTheme
1820import androidx.compose.material3.OutlinedButton
1921import androidx.compose.material3.Text
22+ import androidx.compose.material3.AlertDialog
2023import androidx.compose.runtime.Composable
24+ import androidx.compose.runtime.getValue
25+ import androidx.compose.runtime.livedata.observeAsState
2126import androidx.compose.ui.Alignment
2227import androidx.compose.ui.Modifier
2328import androidx.compose.ui.draw.alpha
@@ -47,6 +52,8 @@ fun ColumnScope.SlotFlashContent(
4752 navController : NavController
4853) {
4954 val context = LocalContext .current
55+ val showDialog by viewModel.showCautionDialog.observeAsState()
56+
5057 if (! listOf (" /flash/ak3" , " /flash/image/flash" , " /backup/backup" ).any { navController.currentDestination!! .route!! .endsWith(it) }) {
5158 SlotCard (
5259 title = stringResource(if (slotSuffix == " _a" ) R .string.slot_a else if (slotSuffix == " _b" ) R .string.slot_b else R .string.slot),
@@ -178,7 +185,7 @@ fun ColumnScope.SlotFlashContent(
178185 Column (verticalArrangement = Arrangement .spacedBy(8 .dp)) {
179186 Text (" You have flashed AnyKernel Zip to inactive slot!" )
180187 Text (" But the active slot is not changed after flashing." )
181- Text (" Use bootctl to change active slot or return to System Updater to complete OTA." )
188+ Text (" Change active slot or return to System Updater to complete OTA." )
182189 Text (" Do not reboot from here, unless you know what you are doing." )
183190 }
184191 },
0 commit comments