Questions tagged [webchromeclient]

WebChromeClient is an Android class to intercept JavaScript dialogs, loading progress, and other events.

WebChromeClient is an Android class to intercept a Webkit Webview's JavaScript dialogs, loading progress, and other events.

Resources

137 questions
1
vote
0 answers

WebView can't get location

I'm trying to open Google maps in webView with custom WebChromeClient and get my location, but map says that it can not set the location. Full code: import android.Manifest; import android.content.pm.PackageManager; import…
Bullshit
  • 11
  • 1
1
vote
1 answer

How to support WebGL with Chrome in webView android

I want show a 3D Model in WebView from a link, but in webView it has not support for WebGl. I tried: webView.setWebChromeClient(new WebChromeClient()); but its not working.
1
vote
0 answers

How to edit Exif Interface Data (rotate) of Captured Image's URI

I'm trying to upload a captured photo to a WebView in Android after triggering the onShowFileChooser method of Android's WebChromeClient. Everything works fine, except all images taken in portrait mode are rotated to landscape. In onActivityResult,…
airowe
  • 794
  • 2
  • 9
  • 29
1
vote
1 answer

unable to get webview to show video fullscreen

i have created an android application to preview my website that has mp4 video player, it works fine but im unable to preview it on full screen when i click on video enlarge icon. Please note that im a new to this , been only learning this for 3…
kallo kallo
  • 27
  • 1
  • 7
1
vote
2 answers

android.webkit.PermissionRequest can't be resolved

I want to override the public void onPermissionRequest(PermissionRequest) method for my WebChromeClient-object. Here is my code: mWebView.setWebChromeClient(new WebChromeClient() { @Override public void onPermissionRequest(final…
000000000000000000000
  • 1,467
  • 1
  • 19
  • 38
1
vote
1 answer

How to log different types of webview javascript messages to java ide console

The well-known way to log messages from webview javascript to java ide console is webView.setWebChromeClient(new WebChromeClient() { @Override public boolean onConsoleMessage(ConsoleMessage cm) { …
alexshr
  • 989
  • 8
  • 12
1
vote
2 answers

Android WebView issue on override url loading

I’m trying to override url loading when clicking on a link on an app WebView. The page loads but the WebView will keep it’s last scroll position and content size. Is there some parameter I forgot to set on the WebView to reset the content size and…
1
vote
1 answer

Webview HTML Video fullscreen - onShowCustomView() called only once

I am using HTML video tag to play video in android Webview. However, when I try to press the fullscreen button, the onShowCustomView() from webview chrome client is called only the first time. Every subsequent time I press the fullscreen button, the…
blueaac
  • 147
  • 1
  • 11
1
vote
1 answer

WebChromeClient OnJSAlert is not called

I'm running a JS script in a WebView. The script alerts a message to the WebView, and I want to receive it in my app. The problem is that onJSAlert is not called nor I can use @Override annotaion when definig the method. My imports are - import…
TDG
  • 5,909
  • 3
  • 30
  • 51
1
vote
0 answers

Android WebChromeClient SSL Url

Is there any possibility to load a ssl url in a WebView with WebChromeClient? I need WCC for an image chooser because this doesnt work in normal WebViewClient but I could not get the SSL working in WebChromeClient. Can anyone help me?
Phil
  • 943
  • 2
  • 6
  • 18
1
vote
1 answer

Do something if WebView url contains a string

I have a WebView in which I load a webpage. In this webpage the user needs to do some actions. A specific action needs to be executed when the user arrives on a specific webpage. This action should execute automatically. How can I continuously…
1
vote
1 answer

Get loaded resource files list from android webview

Is there any way to get the currently successfully loaded and not loaded files from URL into android webview. That is, if I am loading the following, 1.js, 2.js, 3.js 1.css, 2.css, 3.css in html page and load the html file into android webview. I…
Karthick
  • 1,241
  • 5
  • 20
  • 43
1
vote
0 answers

How to autoplay youtube videos in Android WebChromeClient

I have created a simple APK for Android that uses WebChromeClient mWebChromeClient = new myWebChromeClient(); webView.setWebChromeClient(mWebChromeClient); webView.getSettings().setJavaScriptEnabled(true); …
1
vote
1 answer

Android Service which run every hour to get data from Webservice and updates localStorage webview chromeclinet

In my Android App, I'm retrieving data from localStorage and showing in listview. Now I want it to get the updated data from the webservice even when app is closed. I am using webchromeclient. I have tried with services but it starts only with app…
1
vote
1 answer

Android using both WebViewClient and WebChromeClient

I need to manipulate the links in the html so i'm using a WebViewClient to do it. The problem is I've got some iframes that load local html pages and they aren't displyed. But, if i use the WebChromeClient they works! So, i want to use the both of…
BlackShawarna
  • 247
  • 8
  • 23