[英]Can't type inside a WebView
I have a problem interacting with a WebView
. 我在与WebView
交互时遇到问题。 I'm showing an HTML login form within a WebView
and I can't type inside of any of the input fields of the forms. 我在WebView
显示HTML登录表单,我无法在表单的任何输入字段内输入。 I do can interact with the links, select boxes, buttons, etc. 我可以与链接,选择框,按钮等进行交互。
Here is an example of my code. 这是我的代码示例。 Basically I'm retrieving the web view from the xml and setting it a WebViewClient
and a WebChromeClient
. 基本上我正在从xml中检索Web视图并将其设置为WebViewClient
和WebChromeClient
。
webview = (WebView) findViewById(R.id.loginWebview);
webview.getSettings().setJavaScriptEnabled(true);
WebViewClient client = new WebViewClient();
webview.setWebViewClient(client);
webview.setWebChromeClient(new WebChromeClient());
webview.loadUrl("http://www.google.com");
Any ideas? 有任何想法吗?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.