[TIMOB-25629] Android : Webview with fullscreen window not working as expected
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | None |
Status | Closed |
Resolution | Invalid |
Resolution Date | 2018-03-13T21:51:19.000+0000 |
Affected Version/s | Release 7.0.0, Release 7.0.1 |
Fix Version/s | n/a |
Components | Android |
Labels | escalation |
Reporter | Aminul Islam |
Assignee | Gary Mathews |
Created | 2017-12-25T18:20:15.000+0000 |
Updated | 2018-08-06T17:37:04.000+0000 |
Description
I am coming across an issue with webview for android. I have explained it in this screencast (video/audio).
https://screencast-o-matic.com/watch/cblZFY29zJ
Steps:
1. Create an example apps with fullscreen window.
2. Add a webview with the following URL : https://wallet.gbsinfosolutions.com/index.php/mobile-topup'
3. Click on cardholder name text field in webview.
4. Webview stopped scroll
Note: This issue only for Android with fullscreen window.
Test Code :
var webview = Titanium.UI.createWebView({
url : 'https://wallet.gbsinfosolutions.com/index.php/mobile-topup'
});
var window = Titanium.UI.createWindow({
fullscreen:true
});
window.add(webview);
window.open({
modal : true
});
<android xmlns:android="http://schemas.android.com/apk/res/android">
<manifest>
<application android:theme="@style/Theme.AppCompat.Translucent.NoTitleBar.Fullscreen"/>
</manifest>
</android>
Attachments
File | Date | Size |
---|---|---|
0-sa-d2-899e7fd926716b5dc565ee9246b85508.jpg | 2017-12-25T18:23:27.000+0000 | 74197 |
[~gmathews] Can you take a look and comment?
Thanks for the detailed test case. Google states [here](https://developer.android.com/reference/android/view/WindowManager.LayoutParams.html#FLAG_FULLSCREEN), using a fullscreen Window will ignore the
SOFT_INPUT_ADJUST_RESIZE
flag; preventing the window from resizing. Which is necessary for the WebView to resize above the keyboard and display the hidden content. Unfortunately, there is no workaround for this. You cannot use a fullscreen window if you want your WebView to resize correctly. I suggest removing thefullscreen
property and theme, and addingTi.UI.Android.SOFT_INPUT_ADJUST_RESIZE
to resolve the issue.Closing as invalid. If incorrect, please reopen.