Skip to content

Commit c2c299b

Browse files
kollivierdbnicholson
authored andcommitted
Resize webview when keyboard is shown
When the adjust mode is unspecified, Android will not resize the webview when showing the on screen keyboard to keep the input element on screen. Explicitly instruct it to use `adjustResize` mode. Possibly this is because the webview bootstrap uses an `AbsoluteLayout` as the top level widget. See https://developer.android.com/guide/topics/manifest/activity-element#wsoft for details. (cherry picked from commit 9ca92f4)
1 parent c6b63be commit c2c299b

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

pythonforandroid/bootstraps/webview/build/templates/AndroidManifest.tmpl.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@
7070
{% if args.activity_launch_mode %}
7171
android:launchMode="{{ args.activity_launch_mode }}"
7272
{% endif %}
73+
android:windowSoftInputMode="adjustResize"
7374
>
7475
<intent-filter>
7576
<action android:name="android.intent.action.MAIN" />

0 commit comments

Comments
 (0)