上周我从 Cordova 2.6.0 升级到了 2.9.0。自从我遇到了似乎无法摆脱的 dalvik 错误,无论我尝试什么。它不会使我的应用程序崩溃,但是,我无法再使用 File API。我正在 Android 2.2 中测试我的应用程序,我的 minSDK 是 8,我的 targetSDK 是 17,我也在针对 17 构建。这是日志猫:
09-02 13:48:00.148: D/JsMessageQueue(1037): Set native->JS mode to 2
09-02 13:48:00.148: I/CordovaWebView(1037): Disabled addJavascriptInterface() bridge since Android version is old.
09-02 13:48:00.148: E/dalvikvm(1037): Could not find class 'android.webkit.WebResourceResponse', referenced from method org.apache.cordova.CordovaWebViewClient.getWhitelistResponse
09-02 13:48:00.148: W/dalvikvm(1037): VFY: unable to resolve new-instance 130 (Landroid/webkit/WebResourceResponse;) in Lorg/apache/cordova/CordovaWebViewClient;
09-02 13:48:00.158: W/dalvikvm(1037): VFY: unable to find class referenced in signature (Landroid/webkit/WebResourceResponse;)
09-02 13:48:00.158: W/dalvikvm(1037): VFY: unable to find class referenced in signature (Landroid/webkit/WebResourceResponse;)
09-02 13:48:00.158: W/dalvikvm(1037): VFY: unable to find class referenced in signature (Landroid/webkit/WebResourceResponse;)
09-02 13:48:00.158: D/DroidGap(1037): DroidGap.init()
09-02 13:48:00.168: D/CordovaWebView(1037): >>> loadUrl(file:///android_asset/www/index.html)
09-02 13:48:00.168: D/PluginManager(1037): init()
09-02 13:48:00.178: D/CordovaWebView(1037): >>> loadUrlNow()
有人知道这个奇怪问题的解决方案吗?