gpt4 book ai didi

javascript - 如何显示 android 的启动画面? Cordova

转载 作者:太空宇宙 更新时间:2023-11-04 12:10:42 26 4
gpt4 key购买 nike

这是我通过 CLI 的过程

cordova create project

-

cordova platform add android

-

i created my own res folder into the root of the project

-

then copied all the files to the respective folder and added the configuration to the config.xml that exists in the root of project: it looks like this

这是我选择每个启动画面尺寸的地方:https://github.com/phonegap/phonegap/wiki/App-Splash-Screen-Sizes

<gap:splash src="res/android/drawable-port-ldpi.png" gap:platform="android" gap:density="ldpi" gap:qualifier="port-ldpi"/>
<gap:splash src="res/android/drawable-port-mdpi.png" gap:platform="android" gap:density="mdpi" gap:qualifier="port-mdpi"/>
<gap:splash src="res/android/drawable-port-hdpi.png" gap:platform="android" gap:density="hdpi" gap:qualifier="port-hdpi"/>
<gap:splash src="res/android/drawable-port-xhdpi.png" gap:platform="android" gap:density="xhdpi" gap:qualifier="port-xhdpi"/>

<gap:splash src="res/android/drawable-land-ldpi.png" gap:platform="android" gap:density="ldpi" gap:qualifier="land-ldpi"/>
<gap:splash src="res/android/drawable-land-mdpi.png" gap:platform="android" gap:density="mdpi" gap:qualifier="land-mdpi"/>
<gap:splash src="res/android/drawable-land-hdpi.png" gap:platform="android" gap:density="hdpi" gap:qualifier="land-hdpi"/>
<gap:splash src="res/android/drawable-land-xhdpi.png" gap:platform="android" gap:density="xhdpi" gap:qualifier="land-xhdpi"/>

-

but still, the splashscreen doesn't show

然后我去了 phonegap 文档,找到了一些与 splashscreen 插件相关的东西。 https://github.com/apache/cordova-plugin-splashscreen#android-quirks

对我来说,不清楚应该给 foo 什么值甚至我应该把文件放在哪里。此外,该插件没有指定它如何处理非 9patch 图像。

有人可以帮助我吗?

最佳答案

我相信你需要提供一个默认的:

<gap:splash src="splash.png" width="320" height="125" />

关于javascript - 如何显示 android 的启动画面? Cordova ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29076374/

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