0

I'm using the Phonegap Build service (From Dreamweaver CS6) and I've been working with this template: http://themeforest.net/item/tiger-jquery-mobile-web-template-web-app/3018322 which includes a lot of js and css files. The problem is that when the splash screen dissapears, the application hasn't loaded all the js and css files needed to display the application correctly, and some features (which work on Android) like the gallery slideshow doesn't work. Also, when I start the Android application, it looks like a web page without css for a while, but it displays the app correctly after few seconds.

4

1 回答 1

0

您是否按照phonegap 文档添加启动画面?

假设您使用的是最新版本的 phonegap (2.8.0),请将这些行添加到扩展 phonegap 的主要 java 类中:

super.setIntegerProperty("splashscreen", R.drawable.splash);
super.loadUrl(Config.getStartUrl(), 10000);

然后在你的应用程序 JS 中:

document.addEventListener("deviceready", onDeviceReady, false);
function onDeviceReady() {
    navigator.splashscreen.hide();
}
于 2013-06-14T07:45:40.257 回答