Skip to content

Instantly share code, notes, and snippets.

@Ray33
Created November 18, 2016 07:42
Show Gist options
  • Save Ray33/046c015d2abf6ac96a7eae8bb7b890df to your computer and use it in GitHub Desktop.
Save Ray33/046c015d2abf6ac96a7eae8bb7b890df to your computer and use it in GitHub Desktop.
Some webview settings to load web pages
private void initWebView() {
mWebView.setWebViewClient(new WebViewClientImpl());
mWebView.setWebChromeClient(new WebChromeClient());
mWebView.getSettings().setUseWideViewPort(true);
mWebView.getSettings().setLoadWithOverviewMode(true);
mWebView.getSettings().setSupportZoom(true);
mWebView.getSettings().setBuiltInZoomControls(true);
mWebView.loadUrl(mUrl);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment