gpt4 book ai didi

android - Eclipse android phonegap config.xml 不工作?

转载 作者:太空宇宙 更新时间:2023-11-03 11:45:35 24 4
gpt4 key购买 nike

我这辈子都弄不明白为什么我的 XML 文件不起作用。它位于我的 Assets www 文件夹中:图像的链接是正确的 - 我的应用程序的 ID 是相同的,但它仍然不会显示我的初始屏幕或图标!

帮助!

<?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.helloword"
version = "1.0.0">

<name>Testerm Application</name>

<description>
A test application for PhoneGap
</description>

<author href="graemeleighfield@infinitegroup.co.uk" email="graemeleighfield@infinitegroup.co.uk">
Graeme Leighfield
</author>

<icon src="img/icon.png" width="72" height="72" ></icon>

<gap:spalsh src="img/ash.jpg"/>

<feature name="http://api.phonegap.com/1.0/geolocation"/>
<feature name="http://api.phonegap.com/1.0/network"/>
</widget>

最佳答案

是的,config.xml 仅适用于 build.phonegap.com。

使用 Eclipse 构建:

在 res/drawable-hdpi 文件夹中创建一个带有 splash.png 文件名的斜线屏幕。将 super.setIntegerProperty("splashscreen", R.drawable.splash) 添加到您的 App.java 文件中。

public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
super.setIntegerProperty("splashscreen", R.drawable.splash);
super.loadUrl("file:///android_asset/www/index.html");
}

关于android - Eclipse android phonegap config.xml 不工作?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7517443/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com