Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disable webview browser tester ( android )

Tags:

android

I download last version of android studio , keep all up to date. VERSION is 2.2.2 .

I cant find how to remove tester browser from my app . I just wanna to use webView control not browser tester .

like image 446
Nikola Lukic Avatar asked Feb 06 '23 20:02

Nikola Lukic


1 Answers

I fixed it. I forgot to add this line:

WebView.setWebViewClient(new WebViewClient());

What heppend was that it actually opened the browser after redirecting instead of the WebView. For some reason it opens this webview tester instead of the browser, so it's misleading.

Full code:

WebView webview = (WebView)findViewById(R.id.webView);
webview .setWebViewClient(new WebViewClient());
webView.loadUrl("https://...");
like image 51
Ronen Festinger Avatar answered Feb 08 '23 11:02

Ronen Festinger