Skip to content
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

如何关闭OverScrollWebView下滑拖动 #4

Open
onexuan opened this issue Jun 21, 2017 · 2 comments
Open

如何关闭OverScrollWebView下滑拖动 #4

onexuan opened this issue Jun 21, 2017 · 2 comments

Comments

@onexuan
Copy link

onexuan commented Jun 21, 2017

经测试WebView网页长时,有时只加载一屏,与OverScrollWebView下滑拖动有冲突,如何关闭OverScrollWebView下滑拖动
可测试http://www.baidu.com 然后点击百度的主界面的新闻,有时只显示一屏,无法下滑

@Mixiaoxiao
Copy link
Owner

经测试,在安卓4.1和5.1系统中没有问题。
WebView设置如下:
WebSettings settings = webView.getSettings(); settings.setJavaScriptEnabled(true); settings.setSupportMultipleWindows(true); settings.setSupportZoom(true); settings.setBuiltInZoomControls(true); settings.setDisplayZoomControls(false);// settings.setGeolocationEnabled(true); settings.setJavaScriptCanOpenWindowsAutomatically(true); settings.setSupportMultipleWindows(true); settings.setAppCacheEnabled(true); settings.setDomStorageEnabled(true); settings.setUseWideViewPort(true); settings.setLoadWithOverviewMode(true); settings.setCacheMode(WebSettings.LOAD_DEFAULT); webView.loadUrl("https://news.baidu.com/news");

@onexuan
Copy link
Author

onexuan commented Jul 14, 2017

我在android 6.0.1上不行

WebSettings settings = overScrollWebView.getSettings();
settings.setJavaScriptEnabled(true);
settings.setSupportMultipleWindows(true);
settings.setSupportZoom(true);
settings.setBuiltInZoomControls(true);
settings.setDisplayZoomControls(false);//
settings.setGeolocationEnabled(true);
settings.setJavaScriptCanOpenWindowsAutomatically(true);
settings.setSupportMultipleWindows(true);
settings.setAppCacheEnabled(true);
settings.setDomStorageEnabled(true);
settings.setUseWideViewPort(true);
settings.setLoadWithOverviewMode(true);
settings.setCacheMode(WebSettings.LOAD_DEFAULT);
overScrollWebView.loadUrl("https://www.baidu.com");

加载百度首页后,点首页一编文章,出来加载一半

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

No branches or pull requests

2 participants