我创建了一个phonegap项目,该平台是android并添加了启动画面,但它没有显示。
我已经通过phonegap docs(http://docs.phonegap.com/en/3.5.0/config_ref_images.md.html)跟踪了android中关于splash scrren的所有说明
并在所有平台/ android / res / drawable *目录中添加所有启动画面
我的config.xml文件是
<?xml version='1.0' encoding='utf-8'?>
<widget id="com.vertismirai.docconnect" version="0.0.1" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<name>MyApp</name>
<description>
A sample Apache Cordova application that responds to the deviceready event.
</description>
<author email="dev@cordova.apache.org" href="http://cordova.io">
Apache Cordova Team
</author>
<feature name="SplashScreen">
<param name="android-package" value="org.apache.cordova.splashscreen.SplashScreen" />
</feature>
<icon src="res/drawable/icon.png" />
<platform name="android">
<icon src="res/drawable-ldpi/icon.png" density="ldpi" />
<icon src="res/drawable-mdpi/icon.png" density="mdpi" />
<icon src="res/drawable-hdpi/icon.png" density="hdpi" />
<icon src="res/drawable-xhdpi/icon.png" density="xhdpi" />
</platform>
<preference name="SplashScreen" value="screen" />
<preference name="SplashScreenDelay" value="10000" />
<content src="index.html" />
<access origin="*" />
</widget>
答案 0 :(得分:0)
Cordova将设备级API实现为插件。使用命令行界面中描述的CLI&gt;插件命令为项目添加此功能: 请使用以下链接获取更多信息
http://docs.phonegap.com/en/3.3.0/cordova_splashscreen_splashscreen.md.html