Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

getting an error in webview on ice cream sandwich

Error is

java.lang.Throwable: EventHub.removeMessages(int what = 107) is not supported before the WebViewCore is set up.

I am calling a

webview.loadUrl("javascript:myJavaMethod(" + itemArr + "," + telcoID + ");");

on the

webview.setWebViewClient(new WebViewClient() {
            @Override
            public void onPageFinished(WebView view, String url) {

this is a webview playing a flash video player, all is good on 2.2, 2.3.3 etc, tried it on ice cream sandwich and no visible error (other than its just a black screen nor video playing)

Any thoughts.

like image 258
craigk Avatar asked Dec 18 '11 23:12

craigk


2 Answers

I know this topic is old, but I used it to find my solution to that 107 error. My fix was to replace the deprecated:

webview.getSettings().setPluginsEnabled (true);

to

webview.getSettings().setPluginState(PluginState.ON);

Now it plays the video and error free.

like image 88
firefistace Avatar answered Oct 21 '22 10:10

firefistace


I had the same problem until I added the webview to the view dinamically.

like image 1
yoryo Avatar answered Oct 21 '22 12:10

yoryo