Best code examples for WebView setWebChromeClient method (android.webkit.WebView.setWebChromeClient)

These code examples were ranked by Codota’s semantic indexing as the best open source examples for WebView setWebChromeClient method.
You can now enable Codota on your own code to easily search and navigate your Java codebase.

WebView setWebChromeClient examples from Open Source projects
This code example shows how to use the following methods: getSettings, loadUrl, setWebChromeClient, setWebViewClient
25:	mWebView.setWebViewClient(new WebViewClient()); 
26:	mWebView.setWebChromeClient(new WebChromeClient()); 
27:	WebSettings settings = mWebView.getSettings(); 
-
37:	mWebView.loadUrl("http://developer.android.com"); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: getSettings, setWebChromeClient, setWebViewClient
77:	webView = new WebView(this); 
78:	webView.getSettings().setJavaScriptEnabled(true); 
79:	webView.getSettings().setJavaScriptCanOpenWindowsAutomatically(false); 
80:	webView.getSettings().setLayoutAlgorithm(LayoutAlgorithm.NORMAL); 
-
84:	webView.setWebViewClient(webViewClient); 
85:	webView.setWebChromeClient(chromeClient); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: getSettings, loadUrl, setWebChromeClient, setWebViewClient
25:	webView = new WebView(this); 
-
34:	webView.getSettings().setJavaScriptEnabled(true); 
-
36:	webView.setWebChromeClient(new WebChromeClient() { 
-
42:	webView.setWebViewClient(new GoogleAuthWebViewClient()); 
-
44:	webView.loadUrl(AUTH_URL); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: loadUrl, setWebChromeClient
14:	WebView view = new WebView(this); 
15:	view.setWebChromeClient(new WebChromeClient() { 
-
22:	view.loadUrl(getIntent().getData().toString()); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: getSettings, loadUrl, setBackgroundColor, setWebChromeClient
35:	webView.setBackgroundColor(Color.BLACK); 
-
39:	webView.setWebChromeClient(new WebChromeClient()); 
40:	webView.getSettings().setJavaScriptEnabled(true); 
41:	webView.getSettings().setPluginState(PluginState.ON); 
42:	webView.loadUrl(String.format("data:text/html;charset=utf-8,%s", Uri.encode(html))); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: getSettings, loadUrl, setLayoutParams, setScrollBarStyle, setWebChromeClient
29:	WebView webView = new WebView(this); 
30:	webView.setLayoutParams(new LinearLayout.LayoutParams(LayoutParams.FILL_PARENT, 
-
32:	webView.loadUrl(getIntent().getDataString()); 
33:	webView.getSettings().setJavaScriptEnabled(true); 
34:	webView.getSettings().setSupportZoom(true); 
35:	webView.getSettings().setBuiltInZoomControls(true); 
-
37:	webView.setScrollBarStyle(View.SCROLLBARS_INSIDE_OVERLAY); 
38:	webView.getSettings().setUseWideViewPort(true); 
-
42:	webView.setWebViewClient(new WebViewClient() { 
-
67:	webView.setWebChromeClient(new WebChromeClient() { 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: getSettings, setWebChromeClient, setWebViewClient
73:	webView = new WebView(this); 
74:	webView.getSettings().setJavaScriptEnabled(true); 
75:	webView.getSettings().setJavaScriptCanOpenWindowsAutomatically(false); 
76:	webView.getSettings().setLayoutAlgorithm(LayoutAlgorithm.NORMAL); 
-
80:	webView.setWebViewClient(webViewClient); 
81:	webView.setWebChromeClient(chromeClient); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: setWebChromeClient
47:	webView.setWebChromeClient(CalabashChromeClient.this); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: addJavascriptInterface, getSettings, loadUrl, setLayoutParams, setWebChromeClient
24:	mWebView = new WebView(this); 
-
26:	mWebView.setLayoutParams(new LinearLayout.LayoutParams( 
-
29:	mWebView.loadUrl("file:///android_asset/www/index2.html"); 
30:	mWebView.getSettings().setJavaScriptEnabled(true); 
31:	mWebView.addJavascriptInterface(new MyHybrid(), "MyHybrid"); 
32:	mWebView.setWebChromeClient(new WebChromeClient() { 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: addJavascriptInterface, getSettings, loadUrl, setScrollBarStyle, setWebChromeClient
28:	web = new WebView(this); 
29:	web.setScrollBarStyle(WebView.SCROLLBARS_OUTSIDE_OVERLAY); 
-
32:	web.getSettings().setJavaScriptEnabled(true); 
33:	web.getSettings().setAllowFileAccess(true); 
-
35:	web.addJavascriptInterface(javascriptInterface, "android"); 
36:	web.setWebChromeClient(new WebChromeClient()); 
37:	web.setWebViewClient(new GenericWebViewClient()); 
-
56:	web.loadUrl(url); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: getSettings, loadUrl, setWebChromeClient, setWebViewClient
25:	webview = new WebView(this); 
-
33:	webview.getSettings().setJavaScriptEnabled(true); 
34:	webview.getSettings().setCacheMode(WebSettings.LOAD_NO_CACHE); 
-
37:	webview.setWebChromeClient( new WebChromeClient() { 
-
45:	webview.setWebViewClient( new WebViewClient() { 
-
53:	webview.loadUrl(getIntent().getStringExtra("link")); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: getSettings, loadUrl, setWebChromeClient, setWebViewClient
59:	webView.loadUrl(authURL); 
-
73:	webView = new WebView(this); 
74:	webView.getSettings().setJavaScriptEnabled(true); 
75:	webView.getSettings().setBuiltInZoomControls(true); 
76:	webView.setWebViewClient(new CustomWebViewClient()); 
77:	webView.setWebChromeClient(new WebChromeClient() { 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: setHorizontalScrollBarEnabled, setVerticalScrollBarEnabled, getSettings, setBackgroundColor, setWebChromeClient
108:	this.webView = new WebView(context); 
-
152:	WebSettings settings = webView.getSettings(); 
-
158:	webView.setBackgroundColor(0x00000000); // transparent 
159:	webView.setVerticalScrollBarEnabled(false); 
160:	webView.setHorizontalScrollBarEnabled(false); 
161:	webView.setWebChromeClient(new OpenXAdWebChromeClient()); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: setFocusable, setFocusableInTouchMode, setVisibility, getSettings, setWebChromeClient
39:	WebView webview = new WebView( actvitiy ); 
-
42:	webview.setVisibility( View.GONE ); 
43:	webview.setFocusable( true ); 
44:	webview.setFocusableInTouchMode( true ); 
-
46:	webview.setWebChromeClient(new WebChromeClient()); 
-
51:	webview.setWebViewClient( client ); 
-
59:	WebSettings webSettings = webview.getSettings(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: setWebChromeClient, setWebViewClient
97:	super(handle, view); 
-
120:	webView.setWebViewClient(new WebWidget.MoSyncWebViewClient(webWidget)); 
-
123:	webView.setWebChromeClient(new WebWidget.MoSyncWebChromeClient(webWidget)); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: getSettings, loadData, setWebChromeClient
19:	WebView web = new WebView(this); 
-
21:	WebSettings webSettings = web.getSettings(); 
-
27:	web.setWebChromeClient(new MyWebChromeClient()); 
-
31:	web.loadData(htmldata, "text/html", "UTF-8"); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: addJavascriptInterface, clearView, getSettings, loadUrl, setBackgroundColor
25:	WebView w = new WebView(context); 
26:	w.getSettings().setBuiltInZoomControls(useDefaultZoomControls); 
-
28:	w.setBackgroundColor(0x00000000); 
29:	w.getSettings().setJavaScriptEnabled(true); 
-
31:	w.setWebChromeClient(new WebChromeClient() { 
-
37:	w.setWebViewClient(new WebViewClient() { 
-
64:	w.addJavascriptInterface(new Object() { 
-
70:	w.clearView(); 
71:	w.loadUrl(getUrlToDisplay()); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: requestFocusFromTouch, getSettings, loadUrl, setHttpAuthUsernamePassword, setScrollBarStyle
30:	WebView webView = new WebView(activity); 
31:	webView.setWebChromeClient(new WebChromeClient()); 
32:	webView.setWebViewClient(new CouchUtils.CustomWebViewClient()); 
33:	webView.getSettings().setJavaScriptEnabled(true); 
34:	webView.getSettings().setDomStorageEnabled(true); 
35:	webView.setScrollBarStyle(WebView.SCROLLBARS_OUTSIDE_OVERLAY); 
-
37:	webView.setHttpAuthUsernamePassword("127.0.0.1", "administrator", user, pass); 
38:	webView.requestFocusFromTouch(); 
39:	webView.getSettings().setCacheMode(WebSettings.LOAD_NO_CACHE); 
-
41:	webView.loadUrl(url); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: setDrawingCacheEnabled, setOnKeyListener, getSettings, setWebChromeClient, setWebViewClient
50:	mWebView = new WebView(getActivity()); 
-
56:	mWebView.setWebChromeClient(new WebChromeClient() { 
-
62:	mWebView.setOnKeyListener(new OnKeyListener() { 
-
72:	mWebView.setWebViewClient(new InnerWebViewClient()); // forces it to 
-
76:	mWebView.setDrawingCacheEnabled(true); 
77:	mWebView.getSettings().setJavaScriptEnabled(true); 
78:	mWebView.getSettings().setPluginState(WebSettings.PluginState.ON); 
79:	mWebView.getSettings().setAppCacheEnabled(true); 
80:	mWebView.getSettings().setDomStorageEnabled(true); 
81:	mWebView.getSettings().setLoadWithOverviewMode(true); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: getSettings, setWebChromeClient
54:	webview.getSettings().setGeolocationDatabasePath(activity.getFilesDir().getAbsolutePath()); 
55:	webview.getSettings().setDatabaseEnabled(true); 
56:	webview.setWebChromeClient(new WebChromeClient() { 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: destroy, setWebChromeClient, setWebViewClient, stopLoading
36:	this.web.stopLoading(); 
37:	this.web.setWebChromeClient(null); 
38:	this.web.setWebViewClient(null); 
-
40:	this.web.destroy(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: addJavascriptInterface, getSettings, loadUrl, setWebChromeClient, setWebViewClient
69:	webView = new WebView(activity); 
70:	webView.getSettings().setJavaScriptEnabled(true); 
71:	webView.setWebChromeClient(new WebChromeClient() {  // Purely for debugging. 
-
78:	webView.setWebViewClient(new WebViewClient() {  // Purely for debugging. 
-
87:	webView.addJavascriptInterface( 
-
89:	webView.loadUrl(gaeUrl); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: getSettings, loadUrl, setWebChromeClient, setWebViewClient
21:	WebView webview = new WebView(this); 
-
25:	webview.getSettings().setJavaScriptEnabled(true); 
-
29:	webview.setWebChromeClient(new WebChromeClient() { 
-
39:	webview.setWebViewClient(new WebViewClient() { 
-
49:	webview.loadUrl(URL); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: setHorizontalScrollBarEnabled, setVerticalScrollBarEnabled, addJavascriptInterface, getSettings, loadUrl
121:	webView = new WebView(getContext()); 
122:	webView.setLayoutParams(FILL); 
123:	webView.setHorizontalScrollBarEnabled(false); 
124:	webView.setVerticalScrollBarEnabled(false); 
125:	webView.getSettings().setJavaScriptEnabled(true); 
126:	webView.getSettings().setSavePassword(false); 
127:	webView.getSettings().setSaveFormData(false); 
128:	webView.getSettings().setRenderPriority(HIGH); 
-
130:	webView.setWebChromeClient(new WebChromeClient() { 
-
137:	webView.setWebViewClient(new WebViewClient() { 
-
171:	webView.addJavascriptInterface(new HappyDroidJavascriptInterface(getContext(), this), "happyDroid"); 
-
174:	webView.loadUrl(uriToLoad); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: setVerticalScrollBarEnabled, getSettings, loadUrl, setLayoutParams, setWebChromeClient
175:	webView = new WebView(this); 
-
178:	webView.setLayoutParams(wvParams); 
179:	WebSettings webSettings = webView.getSettings(); 
180:	webView.setVerticalScrollBarEnabled(false); 
-
184:	webView.loadUrl(path); 
185:	webView.setWebChromeClient(new WebChromeClient() { 
-
198:	webView.setWebViewClient(new WebViewClient() { 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: destroy, setWebChromeClient, setWebViewClient, stopLoading
272:	webview.stopLoading(); 
273:	webview.setWebChromeClient(null); 
274:	webview.setWebViewClient(null); 
275:	webview.destroy(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: addJavascriptInterface, getSettings, setWebChromeClient
27:	webView = new WebView(this); 
28:	webView.getSettings().setJavaScriptEnabled(true); 
29:	webView.addJavascriptInterface(this,"voteApp"); 
30:	webView.setWebChromeClient(new WebChromeClient(){ 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: addJavascriptInterface, getSettings, loadDataWithBaseURL, setWebChromeClient
89:	mWebView 		= new WebView(context); 
-
94:	WebSettings webSettings = mWebView.getSettings(); 
-
100:	mWebView.setWebChromeClient(new ChannelAPIWebChromeClient()); 
101:	mWebView.addJavascriptInterface(mJsInterface, "channelAPI"); 
102:	mWebView.loadDataWithBaseURL(null, CHANNEL_API_JAVASCRIPT_START + gaeChannelApiSource + CHANNEL_API_JAVASCRIPT_END, "text/html", "utf-8", null); 
Full Snippet Info
5
CodeRank
This code example shows how to use the following methods: setHorizontalScrollBarEnabled, setVerticalScrollBarEnabled, setVisibility, getSettings, loadUrl
183:	webView = new WebView(getContext()); 
184:	webView.setVisibility(View.INVISIBLE); 
185:	webView.setVerticalScrollBarEnabled(false); 
186:	webView.setHorizontalScrollBarEnabled(false); 
187:	webView.setWebViewClient(new AuthenticationWebViewClient()); 
188:	webView.setWebChromeClient(new AuthenticationWebChromeClient()); 
189:	webView.getSettings().setJavaScriptEnabled(true); 
190:	webView.setLayoutParams(FILL); 
191:	webView.getSettings().setSavePassword(false); 
192:	webView.loadUrl(authUrl); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: addJavascriptInterface, getSettings, loadUrl, setWebChromeClient
87:	view = new WebView(this); 
88:	WebSettings settings = view.getSettings(); 
-
100:	view.setWebChromeClient(new WebChromeClient() { @Override public void onProgressChanged(WebView view, int progress) { setProgress(progress * 1000); }}); 
101:	view.addJavascriptInterface(javaInterface, "java"); 
102:	view.loadUrl("file:///android_asset/index.html"); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: getSettings, loadUrl, setWebChromeClient, setWebViewClient
30:	webview = new WebView(this); 
31:	webview.getSettings().setJavaScriptEnabled(true); 
-
33:	webview.setWebChromeClient(new WebChromeClient() { 
-
38:	webview.setWebViewClient(new WebViewClient() { 
-
48:	webview.loadUrl(ITIS_WAP_URL); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: clearCache, getSettings, loadUrl, setLayoutParams, setWebChromeClient
33:	mainView=new WebView(this); 
-
35:	mainView.setLayoutParams(new LayoutParams(display.getWidth(), display.getHeight())); 
36:	mainView.clearCache(true); 
37:	mainView.setWebViewClient(new WebViewSampleClient()); 
38:	mainView.setWebChromeClient(new WebChromeClient()); 
-
44:	mainView.getSettings().setJavaScriptEnabled(true); 
-
46:	mainView.loadUrl("file:///android_asset/killer.htm"); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: setId, getSettings, loadUrl, setWebChromeClient, setWebViewClient
78:	WebView webview = new WebView(this); 
79:	webview.setId(id); 
-
81:	webview.getSettings().setJavaScriptEnabled(true); 
82:	webview.getSettings().setDomStorageEnabled(true); 
-
85:	webview.setWebChromeClient(new WebChromeClient() { 
-
93:	webview.setWebViewClient(new WebViewClient() { 
-
114:	webview.loadUrl(url); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: setHorizontalScrollBarEnabled, getSettings, loadUrl, setScrollBarStyle, setWebChromeClient
83:	mWebView=new WebView(this); 
-
89:	mWebView.setHorizontalScrollBarEnabled(true); 
90:	mWebView.setScrollBarStyle(View.SCROLLBARS_INSIDE_OVERLAY) ;//去掉右边白色边框 
-
92:	WebSettings mWebSettings = mWebView.getSettings(); 
-
104:	mWebView.setWebViewClient(client); 
-
106:	mWebView.setWebChromeClient(new WebChromeClient() 
-
119:	mWebView.loadUrl(extra_uri); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: setOnClickListener, destroy, setWebChromeClient, setWebViewClient
57:	if(mwvWebView != null)	mwvWebView.setOnClickListener(null); 
58:	if(mwvWebView != null)	mwvWebView.setWebViewClient(null); 
59:	if(mwvWebView != null)	mwvWebView.setWebChromeClient(null); 
60:	if(mwvWebView != null)	mwvWebView.destroy(); 
Full Snippet Info
5
CodeRank
This code example shows how to use the following methods: setVerticalScrollBarEnabled, addJavascriptInterface, getSettings, setInitialScale, setLayoutParams
83:	appView = new WebView(this); 
84:	appView.setLayoutParams(webviewParams); 
-
90:	appView.setWebChromeClient(new EclairClient(this)); 
-
92:	appView.setWebChromeClient(new GapClient(this)); 
-
94:	appView.setInitialScale(100); 
95:	appView.setVerticalScrollBarEnabled(false); 
-
97:	WebSettings settings = appView.getSettings(); 
-
123:	gap = new PhoneGap(this, appView); 
124:	geo = new GeoBroker(appView, this); 
125:	accel = new AccelListener(this, appView); 
126:	launcher = new CameraLauncher(appView, this); 
127:	mContacts = new ContactManager(this, appView); 
128:	fs = new FileUtils(appView); 
129:	netMan = new NetworkManager(this, appView); 
130:	mCompass = new CompassListener(this, appView); 
-
133:	appView.addJavascriptInterface(gap, "DroidGap"); 
134:	appView.addJavascriptInterface(geo, "Geo"); 
135:	appView.addJavascriptInterface(accel, "Accel"); 
136:	appView.addJavascriptInterface(launcher, "GapCam"); 
137:	appView.addJavascriptInterface(mContacts, "ContactHook"); 
138:	appView.addJavascriptInterface(fs, "FileUtil"); 
139:	appView.addJavascriptInterface(netMan, "NetworkManager"); 
140:	appView.addJavascriptInterface(mCompass, "CompassHook"); 
Full Snippet Info
0
CodeRank
This code example shows how to use the following methods: requestFocus, setFocusable, setFocusableInTouchMode, setOnFocusChangeListener, addJavascriptInterface
38:	WebView view = new WebView(driver.getActivity()); 
39:	view.setWebChromeClient(chromeClient); 
40:	view.setWebViewClient(viewClient); 
-
42:	final float zoom = view.getScale(); 
-
44:	view.setOnFocusChangeListener(new View.OnFocusChangeListener() { 
-
53:	view.addJavascriptInterface(jsInterface, "webdriver"); 
-
80:	view.clearCache(true); 
81:	view.clearFormData(); 
82:	view.clearHistory(); 
83:	view.clearView(); 
-
85:	view.requestFocus(View.FOCUS_DOWN); 
86:	view.setFocusable(true); 
87:	view.setFocusableInTouchMode(true); 
-
90:	WebSettings settings = view.getSettings(); 
-
114:	view.enablePlatformNotifications(); 
115:	view.setNetworkAvailable(true); 
Full Snippet Info
-2
CodeRank
Related WebView setWebChromeClient Questions & Answers:
setWebChromeClient Method Overview
Sets the chrome handler.
See Also