我已经使用sencha touch2完成了应用程序,使用手机间隙构建我正在打包这些文件。现在我可以在启动应用程序时显示splash .png图像。但我需要在启动应用程序时向用户显示启动视频。所以我添加了源图像路径添加视频路径没有得到启动视频。 我想知道是否支持电话差距支持启动视频?如果它支持意味着它将支持哪种类型的视频格式。可以告诉我如何实现这一目标。
以下是启动图像的代码:Config.xml(工作)
<?xml version="1.0" encoding="UTF-8" ?>
<widget xmlns = "http://www.w3.org/ns/widgets"
xmlns:gap = "http://phonegap.com/ns/1.0"
id = "com.phonegap.example"
versionCode="10"
version = "1.0.0">
<!-- versionCode is optional and Android only -->
<name>ABC</name>
<gap:splash src="resources/splash/def.png" width="1024" height="768" />
<gap:splash src="resources/splash/def.png" gap:platform="android" gap:density="ldpi" />
<icon src="resources/icons/xyz.png" gap:platform="ios" width="80" height="80" />
<icon src="resources/icons/xyz.png" gap:platform="android" gap:density="ldpi" width="100" height="100"/>
</widget>
以下是Splash视频的代码:config.xml(不工作)
<?xml version="1.0" encoding="UTF-8" ?>
<widget xmlns = "http://www.w3.org/ns/widgets"
xmlns:gap = "http://phonegap.com/ns/1.0"
id = "com.phonegap.example"
versionCode="10"
version = "1.0.0">
<!-- versionCode is optional and Android only -->
<name>ABC</name>
<gap:splash src="resources/splash/AVIFile.avi.mp4" width="1024" height="768" />
<gap:splash src="resources/splash/AVIFile.avi.mp4" gap:platform="android" gap:density="ldpi" />
<icon src="resources/icons/xyz.png" gap:platform="ios" width="80" height="80" />
<icon src="resources/icons/xyz.png" gap:platform="android" gap:density="ldpi" width="100" height="100"/>
</widget>
答案 0 :(得分:0)
这对我来说很好
<?xml version="1.0" encoding="UTF-8"?>
<widget xmlns = "http://www.w3.org/ns/widgets"
xmlns:gap = "http://phonegap.com/ns/1.0"
id = "com.media.myappindia"
version = "2.0.1">
<title>myappindia</title>
<name>myappindia</name>
<description>
myappindia - my 1st app
</description>
<author href="http://www.myappindia.com/" email="android@myappindia.com">
myappindia Team
</author>
<feature name="http://api.phonegap.com/1.0/device" />
<preference name="phonegap-version" value="2.0.0" />
<preference name="orientation" value="default" />
<preference name="target-device" value="universal" />
<preference name="fullscreen" value="false" />
<preference name="stay-in-webview" value="true" />
<icon src="icon.png" />
<icon src="res/icon/android/icon-36-ldpi.png" gap:platform="android" gap:density="ldpi" />
<icon src="res/icon/android/icon-48-mdpi.png" gap:platform="android" gap:density="mdpi" />
<icon src="res/icon/android/icon-72-hdpi.png" gap:platform="android" gap:density="hdpi" />
<icon src="res/icon/android/icon-96-xhdpi.png" gap:platform="android" gap:density="xhdpi" />
<icon src="res/icon/blackberry/icon-80.png" gap:platform="blackberry" />
<icon src="res/icon/blackberry/icon-80.png" gap:platform="blackberry" gap:state="hover"/>
<icon src="res/icon/ios/icon-57.png" gap:platform="ios" width="57" height="57" />
<icon src="res/icon/ios/icon-72.png" gap:platform="ios" width="72" height="72" />
<icon src="res/icon/ios/icon-57-2x.png" gap:platform="ios" width="114" height="114" />
<icon src="res/icon/ios/icon-72-2x.png" gap:platform="ios" width="144" height="144" />
<icon src="res/icon/webos/icon-64.png" gap:platform="webos" />
<icon src="res/icon/windows-phone/icon-48.png" gap:platform="winphone" />
<icon src="res/icon/windows-phone/icon-173.png" gap:platform="winphone" gap:role="background" />
<gap:splash src="res/screen/android/screen-ldpi-portrait.png" gap:platform="android" gap:density="ldpi" />
<gap:splash src="res/screen/android/screen-mdpi-portrait.png" gap:platform="android" gap:density="mdpi" />
<gap:splash src="res/screen/android/screen-hdpi-portrait.png" gap:platform="android" gap:density="hdpi" />
<gap:splash src="res/screen/android/screen-xhdpi-portrait.png" gap:platform="android" gap:density="xhdpi" />
<gap:splash src="res/screen/blackberry/screen-225.png" gap:platform="blackberry" />
<gap:splash src="res/screen/ios/screen-iphone-portrait.png" gap:platform="ios" width="320" height="480" />
<gap:splash src="res/screen/ios/screen-iphone-portrait-2x.png" gap:platform="ios" width="640" height="960" />
<gap:splash src="res/screen/ios/screen-ipad-portrait.png" gap:platform="ios" width="768" height="1024" />
<gap:splash src="res/screen/ios/screen-ipad-landscape.png" gap:platform="ios" width="1024" height="768" />
<gap:splash src="res/screen/windows-phone/screen-portrait.jpg" gap:platform="winphone" />
<access origin="*" />
</widget>