Pergunta

I build a very simple Sencha-Touch-2 app and deployed it to Eclipse. The app work on Chrome, but on the device I'm getting the following error:

E/dalvikvm(270): Could not find class 'android.webkit.WebResourceResponse', referenced from method org.apache.cordova.CordovaWebViewClient.generateWebResourceResponse

I tried to google it but didn't found solution for me. My App is at android 2.3.1 level and my device is 4.1.1 and it doesn't work on both of them.

Thanks

Foi útil?

Solução

Do you have 'cordova-1.9.0.jar' in your '/libs' folder ?
Make sure this is in /libs folder if you are using ADT 17 or above version.

Outras dicas

I think it could be related with the new name of the lib folder (previously 'lib' now is 'libs'). Try to rename it an check if it works.

Extracted from this answer in SO


EDIT: Other possibility is that ProGuard is messing with the library to fix it you can try this:

-keep public class * extends com.phonegap.api.Plugin 
-keep public class org.apache.cordova.DroidGap 
-keep public class org.apache.cordova.** 
-libraryjars /Users/Nasir/Desktop/libs/commons-codec.jar
-dontwarn android.webkit.*

Extracted from this answer in SO

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top