문제

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

도움이 되었습니까?

해결책

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.

다른 팁

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

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top