You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 3, 2020. It is now read-only.
I have a service containing a webView. I want to move to XWalkView.
However, when doing webView = new XWalkView(this); in my service it throws the following: java.lang.RuntimeException: java.lang.ClassCastException: es.packageName.appName.ServiceWithWebView cannot be cast to android.app.Activity
Using the normal Android WebView in the service works without issues but I now need the XWalkView.
Maybe launch an invisible activity to have something to pass to the constructor? Has anyone done something like this before?
The text was updated successfully, but these errors were encountered:
tulssinep
changed the title
Can't XWalkView(this);
Can't XWalkView(this) in service
Jun 6, 2018
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I have a service containing a webView. I want to move to XWalkView.
However, when doing
webView = new XWalkView(this);
in my service it throws the following:java.lang.RuntimeException: java.lang.ClassCastException: es.packageName.appName.ServiceWithWebView cannot be cast to android.app.Activity
Using the normal Android WebView in the service works without issues but I now need the XWalkView.
Maybe launch an invisible activity to have something to pass to the constructor? Has anyone done something like this before?
The text was updated successfully, but these errors were encountered: