新批次的夜间模式适配代码

This commit is contained in:
2026-07-30 23:38:34 +08:00
parent b6d623a1eb
commit 42a30a73f9
11 changed files with 151 additions and 83 deletions
+31 -13
View File
@@ -1,26 +1,44 @@
pluginManagement {
val flutterSdkPath =
run {
val properties = java.util.Properties()
file("local.properties").inputStream().use { properties.load(it) }
val flutterSdkPath = properties.getProperty("flutter.sdk")
require(flutterSdkPath != null) { "flutter.sdk not set in local.properties" }
flutterSdkPath
}
val flutterSdkPath = run {
val properties = java.util.Properties()
file("local.properties").inputStream().use { properties.load(it) }
val sdkPath = properties.getProperty("flutter.sdk")
require(sdkPath != null) { "flutter.sdk not set in local.properties" }
sdkPath
}
includeBuild("$flutterSdkPath/packages/flutter_tools/gradle")
repositories {
// 🟢 阿里云 gradle-plugin 镜像(专用)
maven {
url = uri("https://maven.aliyun.com/repository/gradle-plugin")
}
// 🟢 阿里云 public 聚合仓库(兜底)
maven {
url = uri("https://maven.aliyun.com/repository/public")
}
google()
mavenCentral()
gradlePluginPortal()
}
}
plugins {
id("dev.flutter.flutter-plugin-loader") version "1.0.0"
id("com.android.application") version "8.9.1" apply false
id("org.jetbrains.kotlin.android") version "2.1.0" apply false
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.PREFER_SETTINGS)
repositories {
// 🟢 阿里云镜像放在最前面
maven { url = uri("https://maven.aliyun.com/repository/public") }
google()
mavenCentral()
}
}
include(":app")
plugins {
id("dev.flutter.flutter-plugin-loader") version "1.0.0"
id("com.android.application") version "8.13.0" apply false
id("org.jetbrains.kotlin.android") version "2.2.21" apply false
}
rootProject.name = "android"
include(":app")