From 9011567126499a96bb4d4660967e009dd6647635 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9rgio=20Santos?= Date: Tue, 3 Dec 2024 11:40:13 +0000 Subject: [PATCH] Fix inset issues --- composeApp/src/androidMain/AndroidManifest.xml | 1 + .../ooni/probe/ui/choosewebsites/ChooseWebsitesScreen.kt | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/composeApp/src/androidMain/AndroidManifest.xml b/composeApp/src/androidMain/AndroidManifest.xml index 34e71252..757e730f 100644 --- a/composeApp/src/androidMain/AndroidManifest.xml +++ b/composeApp/src/androidMain/AndroidManifest.xml @@ -20,6 +20,7 @@ android:name=".MainActivity" android:configChanges="orientation|screenSize|screenLayout|keyboardHidden|mnc|colorMode|density|fontScale|fontWeightAdjustment|keyboard|layoutDirection|locale|mcc|navigation|smallestScreenSize|touchscreen|uiMode" android:launchMode="singleTask" + android:windowSoftInputMode="adjustNothing" android:exported="true"> diff --git a/composeApp/src/commonMain/kotlin/org/ooni/probe/ui/choosewebsites/ChooseWebsitesScreen.kt b/composeApp/src/commonMain/kotlin/org/ooni/probe/ui/choosewebsites/ChooseWebsitesScreen.kt index c17187dd..d61f2abe 100644 --- a/composeApp/src/commonMain/kotlin/org/ooni/probe/ui/choosewebsites/ChooseWebsitesScreen.kt +++ b/composeApp/src/commonMain/kotlin/org/ooni/probe/ui/choosewebsites/ChooseWebsitesScreen.kt @@ -10,6 +10,7 @@ import androidx.compose.foundation.layout.fillMaxSize import androidx.compose.foundation.layout.fillMaxWidth import androidx.compose.foundation.layout.imePadding import androidx.compose.foundation.layout.navigationBars +import androidx.compose.foundation.layout.navigationBarsPadding import androidx.compose.foundation.layout.padding import androidx.compose.foundation.lazy.LazyColumn import androidx.compose.foundation.lazy.itemsIndexed @@ -54,9 +55,7 @@ fun ChooseWebsitesScreen( onEvent: (ChooseWebsitesViewModel.Event) -> Unit, ) { Column( - modifier = Modifier - .padding(WindowInsets.navigationBars.asPaddingValues()) - .background(MaterialTheme.colorScheme.background), + modifier = Modifier.background(MaterialTheme.colorScheme.background), ) { TopBar( title = { Text(stringResource(Res.string.Settings_Websites_CustomURL_Title)) }, @@ -140,6 +139,7 @@ fun ChooseWebsitesScreen( modifier = Modifier .align(Alignment.BottomCenter) .imePadding() + .navigationBarsPadding() .padding(bottom = 16.dp), ) { Icon(