瀏覽代碼

新增应用背景

zhipeng 7 月之前
父節點
當前提交
ee27f1b90e

+ 3 - 0
native/engine/android/app/src/main/res/values/themes.xml

@@ -4,5 +4,8 @@
         <!-- Status bar color. -->
         <item name="android:statusBarColor">@android:color/transparent</item>
         <!-- Customize your theme here. -->
+        <item name="android:windowFullscreen">true</item>
+        <item name="android:windowTranslucentStatus">true</item>
+        <item name="android:windowBackground">@drawable/theme_splash</item>
     </style>
 </resources>

二進制
native/engine/android/res/drawable-xxxhdpi/bg_splash_theme.webp


+ 13 - 0
native/engine/android/res/drawable/theme_splash.xml

@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
+    <item>
+        <shape android:shape="rectangle">
+            <size
+                android:width="1080px"
+                android:height="1920px" />
+        </shape>
+    </item>
+    <item>
+        <bitmap android:src="@drawable/bg_splash_theme" />
+    </item>
+</layer-list>