未知的铬错误:-6:sencha和phonegap

时间:2012-09-15 10:34:23

标签: cordova sencha-touch-2

我在Sencha-touch和phonegap制作应用程序,需要你的帮助。 我使用eclipse在模拟器(android 2.1,4.1)上成功运行了我的应用程序。我在三星手机(android 2.3.3)上成功运行我的应用程序,但是当我在三星galaxy tab 10.1(这是android-4.1.4)上运行它时,它只显示一个白色屏幕。

此外,在Android模拟器4.0.3上,我得到一个带有以下logcat文件的白色屏幕:

09-15 00:10:24.031: I/dalvikvm(635): threadid=3: reacting to signal 3
09-15 00:10:24.101: I/dalvikvm(635): Wrote stack traces to '/data/anr/traces.txt'
09-15 00:10:24.181: D/SoftKeyboardDetect(635): Ignore this event
09-15 00:10:24.271: W/webcore(635): java.lang.Throwable: EventHub.removeMessages(int     what = 107) is not supported before the WebViewCore is set up.
09-15 00:10:24.271: W/webcore(635):     at android.webkit.WebViewCore$EventHub.removeMessages(WebViewCore.java:1683)
09-15 00:10:24.271: W/webcore(635):     at android.webkit.WebViewCore$EventHub.access$7900(WebViewCore.java:926)
09-15 00:10:24.271: W/webcore(635):     at   android.webkit.WebViewCore.removeMessages(WebViewCore.java:1795)
09-15 00:10:24.271: W/webcore(635):     at android.webkit.WebView.sendOurVisibleRect(WebView.java:2917)
09-15 00:10:24.271: W/webcore(635):     at android.webkit.ZoomManager.setZoomScale(ZoomManager.java:593)
09-15 00:10:24.271: W/webcore(635):     at android.webkit.ZoomManager.access$1700(ZoomManager.java:49)
09-15 00:10:24.271: W/webcore(635):     at android.webkit.ZoomManager$PostScale.run(ZoomManager.java:984)
09-15 00:10:24.271: W/webcore(635):     at android.os.Handler.handleCallback(Handler.java:605)
09-15 00:10:24.271: W/webcore(635):     at android.os.Handler.dispatchMessage(Handler.java:92)
09-15 00:10:24.271: W/webcore(635):     at android.os.Looper.loop(Looper.java:137)
09-15 00:10:24.271: W/webcore(635):     at android.app.ActivityThread.main(ActivityThread.java:4424)
09-15 00:10:24.271: W/webcore(635):     at java.lang.reflect.Method.invokeNative(Native Method)
09-15 00:10:24.271: W/webcore(635):     at java.lang.reflect.Method.invoke(Method.java:511)
09-15 00:10:24.271: W/webcore(635):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
09-15 00:10:24.271: W/webcore(635):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
09-15 00:10:24.271: W/webcore(635):     at dalvik.system.NativeStart.main(Native Method)
09-15 00:10:24.311: D/SoftKeyboardDetect(635): Ignore this event
09-15 00:10:24.351: D/gralloc_goldfish(635): Emulator without GPU emulation detected.
09-15 00:10:33.461: I/SqliteDatabaseCpp(635): sqlite returned: error code = 14, msg = cannot open file at line 27701 of [8609a15dfa], db=/data/data/com.napp.www/databases/webview.db
09-15 00:10:33.461: I/SqliteDatabaseCpp(635): sqlite returned: error code = 14, msg = os_unix.c: open() at line 27701 - "" errno=2 path=/CachedGeoposition.db, db=/data/data/com.napp.www/databases/webview.db
09-15 00:10:33.551: D/dalvikvm(635): GC_CONCURRENT freed 127K, 3% free 9362K/9607K, paused 5ms+4ms
09-15 00:10:34.931: D/chromium(635): Unknown chromium error: -6
09-15 00:10:34.931: D/chromium(635): Unknown chromium error: -6
09-15 00:10:34.931: D/chromium(635): Unknown chromium error: -6
09-15 00:17:20.591: D/dalvikvm(635): GC_CONCURRENT freed 422K, 6% free 9382K/9927K, paused 5ms+9ms 
09-15 00:24:16.031: D/dalvikvm(635): GC_CONCURRENT freed 423K, 6% free 9372K/9927K, paused 4ms+4ms

你可以帮我解决问题所在。提前谢谢。

3 个答案:

答案 0 :(得分:5)

上面的答案有效,但是如果您使用的是Ext.Ajax,还需要在配置中添加几个参数,以便找到这些文件。

noCache: false, 
enablePagingParams: false,

很好post on the Sencha forum描述了这个问题和解决方法。

答案 1 :(得分:2)

在任何javascript代码之前使用它:

Ext.Loader.setConfig({ disableCaching: false });
Ext.Ajax.setDisableCaching(false);    

答案 2 :(得分:1)

要使其在不同版本的android中运行,请在任何其他JavaScript之前在HTML文件的标头中添加代码。

<script>        
Ext.Loader.setConfig({
    enabled: true,
    disableCaching: false
    });

    Ext.Ajax.setDisableCaching(false);
</Script>