Skip to content

Resize webview when keyboard is shown #2674

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 22, 2022

Conversation

dbnicholson
Copy link
Contributor

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.

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.
@dbnicholson
Copy link
Contributor Author

Before:
webview-input-unspecified

After:
webview-input-resize

Copy link
Member

@AndreMiras AndreMiras left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for the context and the screenshots

@AndreMiras AndreMiras merged commit 698b6c2 into kivy:develop Sep 22, 2022
@dbnicholson dbnicholson deleted the webview-keyboard-resize branch September 22, 2022 15:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants