启动页控制

This commit is contained in:
2024-10-13 05:03:34 +08:00
parent d98bfe88c5
commit 20a34b569a
6 changed files with 80 additions and 4 deletions

View File

@@ -112,6 +112,7 @@ dependencies {
implementation ("cn.jiguang.sdk:jpush-google:5.4.0") implementation ("cn.jiguang.sdk:jpush-google:5.4.0")
api ("com.tencent.imsdk:imsdk-plus:8.1.6116") api ("com.tencent.imsdk:imsdk-plus:8.1.6116")
implementation("io.github.rroohit:ImageCropView:3.0.1") implementation("io.github.rroohit:ImageCropView:3.0.1")
implementation("androidx.core:core-splashscreen:1.0.1") // 添加 SplashScreen 依赖
} }

View File

@@ -38,7 +38,7 @@
android:name=".MainActivity" android:name=".MainActivity"
android:exported="true" android:exported="true"
android:label="@string/app_name" android:label="@string/app_name"
android:theme="@style/Theme.RiderPro" android:theme="@style/Theme.App.Starting"
android:windowSoftInputMode="adjustResize"> android:windowSoftInputMode="adjustResize">
<intent-filter> <intent-filter>
<action android:name="android.intent.action.MAIN" /> <action android:name="android.intent.action.MAIN" />

View File

@@ -12,6 +12,7 @@ import androidx.compose.material3.Icon
import androidx.compose.material3.MaterialTheme import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.Text import androidx.compose.material3.Text
import androidx.compose.runtime.Composable import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color import androidx.compose.ui.graphics.Color
import androidx.compose.ui.res.painterResource import androidx.compose.ui.res.painterResource
@@ -61,7 +62,9 @@ fun DropdownMenu(
.noRippleClickable { .noRippleClickable {
item.action() item.action()
}) { }) {
Row { Row(
verticalAlignment = Alignment.CenterVertically
) {
Text( Text(
item.title, item.title,
fontWeight = FontWeight.W500 fontWeight = FontWeight.W500

View File

@@ -0,0 +1,64 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="48dp"
android:height="48dp"
android:viewportWidth="48"
android:viewportHeight="48">
<path
android:pathData="M14.156,0L33.844,0A14.156,14.156 0,0 1,48 14.156L48,33.844A14.156,14.156 0,0 1,33.844 48L14.156,48A14.156,14.156 0,0 1,0 33.844L0,14.156A14.156,14.156 0,0 1,14.156 0z"
android:strokeWidth="1"
android:fillColor="#ED1C24"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<group>
<clip-path
android:pathData="M14.156,0L33.844,0A14.156,14.156 0,0 1,48 14.156L48,33.844A14.156,14.156 0,0 1,33.844 48L14.156,48A14.156,14.156 0,0 1,0 33.844L0,14.156A14.156,14.156 0,0 1,14.156 0z"/>
<path
android:pathData="M8.726,10.824l9.223,0l-0.5,2.474l-9.223,0z"
android:strokeWidth="1"
android:fillColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M9.87,15.154l7.507,0l-0.5,2.474l-7.507,0z"
android:strokeWidth="1"
android:fillColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M11.164,19.485l6.785,0l-0.651,2.474l-6.785,0z"
android:strokeWidth="1"
android:fillColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M17.948,9.763l2.821,0.511l-2.926,18.914l-2.821,-0.511z"
android:strokeWidth="1"
android:fillColor="#ED1C24"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M6.508,9.763l2.821,0.511l-0.755,4.881l-2.821,-0.511z"
android:strokeWidth="1"
android:fillColor="#ED1C24"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M8.224,13.474l2.821,0.511l-0.755,4.881l-2.821,-0.511z"
android:strokeWidth="1"
android:fillColor="#ED1C24"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M9.94,18.423l2.821,0.511l-0.755,4.881l-2.821,-0.511z"
android:strokeWidth="1"
android:fillColor="#ED1C24"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M27.16,27.499L21.88,27.499L20.018,38.237L15.327,38.237L20.132,10.367L28.851,10.386C31.852,10.386 34.15,11.113 35.745,12.568C37.341,14.023 38.031,16.046 37.816,18.636C37.676,20.435 37.081,21.995 36.03,23.316C34.979,24.637 33.504,25.674 31.605,26.427L35.688,37.95L35.669,38.237L30.693,38.237L27.16,27.499ZM22.836,23.335L27.249,23.373C28.836,23.373 30.163,22.946 31.228,22.093C32.292,21.24 32.917,20.08 33.102,18.614C33.286,17.186 33.04,16.089 32.363,15.325C31.686,14.56 30.658,14.152 29.28,14.102L24.405,14.083L22.836,23.335Z"
android:strokeWidth="1"
android:fillColor="#FFFFFF"
android:fillType="nonZero"
android:strokeColor="#00000000"/>
</group>
</vector>

View File

@@ -7,4 +7,5 @@
<color name="teal_700">#FF018786</color> <color name="teal_700">#FF018786</color>
<color name="black">#FF000000</color> <color name="black">#FF000000</color>
<color name="white">#FFFFFFFF</color> <color name="white">#FFFFFFFF</color>
<color name="splash_background">#ED1C24</color>
</resources> </resources>

View File

@@ -1,5 +1,12 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<resources> <resources>
<style name="Theme.RiderPro" parent="android:Theme.Material.Light.NoActionBar" >
<style name="Theme.RiderPro" parent="android:Theme.Material.Light.NoActionBar" /> <item name="android:windowNoTitle">true</item>
</style>
<style name="Theme.App.Starting" parent="Theme.SplashScreen">
<item name="android:windowNoTitle">true</item>
<item name="windowSplashScreenBackground">@color/splash_background</item>
<item name="windowSplashScreenAnimatedIcon">@mipmap/rider_pro_logo_red_round</item>
<item name="postSplashScreenTheme">@style/Theme.RiderPro</item>
</style>
</resources> </resources>