trigger.io的Andr​​oid的WebView应用程序 - 键盘后出现的灰色背景关闭或方向改变 [英] trigger.io Android webview app - grey background appearing after keyboard closes or orientation change

查看:261
本文介绍了trigger.io的Andr​​oid的WebView应用程序 - 键盘后出现的灰色背景关闭或方向改变的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我要建包裹的iOS / Android应用程序与Trigger.io的HTML5。

I'm building an html5 wrapped iOS / Android app with Trigger.io.

我有出现在一些场合屏幕上的灰色背景上的Andr​​oid有问题的虚拟键盘关闭后,或之后的手机已经改变了方向。

I have a problem on Android with a grey background appearing on the screen in some occasions after the virtual keyboard has closed, or after the phone has changed orientation.

实施例的屏幕截图如下。

Example screenshots are shown below.

灰色的背景是我的应用程序的页面结束后。有时它是一瞬间可见,直到你做一个动作,如滚动页面,把键盘退,换方向其他时候总是显示的。

The grey background is after the end of my app's page. Sometimes it is visible for a split second, other times it stays visible until you make an action such as scroll the page, bring the keyboard back, change orientation.

这是pretty不和谐关注一下。

It's pretty jarring to look at.

我最想要阻止问题发生,但作为一个临时的解决办法,我会高兴能够灰色设置为我自己的背景颜色,使其不太明显。

I'd ideally like to stop the issue occurring, but as a temporary fix I'd be happy with being able to set the grey to my own background colour to make it less noticeable.

推荐答案

这看起来像HTML不是被当键盘消失重新绘制...没有说清楚,如果你做一些事来引发渲染?

This looks like the HTML's not being re-drawn when the keyboard disappears... does it clear up if you do something to trigger a render?

您用一个框架来这里办理UI?一些可能会尝试做基于可见视一些聪明?

Are you using a framework to handle the UI here? Something that might be trying to do something clever based on the visible viewport?

从我所知道的,问题的根源是没有的WebView重新绘制正确,或者说在你的JavaScript不能视口大小的改变做出响应

From what I can tell, the root of the issue is in the webview not re-drawing correctly, or something in your JavaScript failing to respond to the viewport changing size.

您可以尝试在网络的目标(而不是Android版)上运行的应用程序,然后在你的手机浏览器打开它:如果你能得到足够远的应用程序来创建相同的效果,这将有助于隔离问题的网页视图渲染或JS。

You could try running the app on the "web" target (instead of Android) then opening it in your phone's browser: if you can get far enough into the app to create the same effect it would help isolate the problem to the webview rendering or your JS.

这篇关于trigger.io的Andr​​oid的WebView应用程序 - 键盘后出现的灰色背景关闭或方向改变的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆