Skip to content

Commit 9e755f2

Browse files
committed
example: Set windowSoftInputMode
1 parent 6fdc25c commit 9e755f2

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

composeApp/src/androidMain/AndroidManifest.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
<activity
1111
android:name=".MainActivity"
1212
android:configChanges="orientation|screenSize|screenLayout|keyboardHidden|mnc|colorMode|density|fontScale|fontWeightAdjustment|keyboard|layoutDirection|locale|mcc|navigation|smallestScreenSize|touchscreen|uiMode"
13+
android:windowSoftInputMode="adjustResize"
1314
android:exported="true">
1415
<intent-filter>
1516
<action android:name="android.intent.action.MAIN" />

composeApp/src/commonMain/kotlin/UITest.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import androidx.compose.animation.shrinkHorizontally
77
import androidx.compose.animation.shrinkVertically
88
import androidx.compose.foundation.layout.PaddingValues
99
import androidx.compose.foundation.layout.fillMaxSize
10+
import androidx.compose.foundation.layout.imePadding
1011
import androidx.compose.foundation.layout.padding
1112
import androidx.compose.foundation.layout.statusBarsPadding
1213
import androidx.compose.foundation.pager.PagerState
@@ -148,6 +149,7 @@ fun UITest(
148149
}
149150
) { padding ->
150151
AppHorizontalPager(
152+
modifier = Modifier.imePadding(),
151153
pagerState = pagerState,
152154
topAppBarScrollBehaviorList = topAppBarScrollBehaviorList,
153155
padding = padding,

0 commit comments

Comments
 (0)