diff --git a/V2rayNG/app/build.gradle.kts b/V2rayNG/app/build.gradle.kts
index 3871e279..4051e02a 100644
--- a/V2rayNG/app/build.gradle.kts
+++ b/V2rayNG/app/build.gradle.kts
@@ -1,7 +1,5 @@
plugins {
alias(libs.plugins.android.application)
- alias(libs.plugins.kotlin.android)
- id("com.jaredsburrows.license")
}
android {
@@ -18,8 +16,6 @@ android {
versionCode = envVersionCode?.toIntOrNull() ?: 717
versionName = envVersionName ?: "2.0.17"
-
- multiDexEnabled = true
val abiFilterList = (properties["ABI_FILTERS"] as? String)?.split(';')
splits {
@@ -90,7 +86,7 @@ android {
sourceSets {
getByName("main") {
- jniLibs.srcDirs("libs")
+ jniLibs.directories.add("libs")
}
}
@@ -106,50 +102,6 @@ android {
}
}
- applicationVariants.all {
- val variant = this
- val isFdroid = variant.productFlavors.any { it.name == "fdroid" }
- if (isFdroid) {
- val versionCodes =
- mapOf(
- "armeabi-v7a" to 2, "arm64-v8a" to 1, "x86" to 4, "x86_64" to 3, "universal" to 0
- )
-
- variant.outputs
- .map { it as com.android.build.gradle.internal.api.ApkVariantOutputImpl }
- .forEach { output ->
- val abi = output.getFilter("ABI") ?: "universal"
- output.outputFileName = "v2rayNG_${variant.versionName}-fdroid_${abi}.apk"
- if (versionCodes.containsKey(abi)) {
- output.versionCodeOverride =
- (100 * variant.versionCode + versionCodes[abi]!!).plus(5000000)
- } else {
- return@forEach
- }
- }
- } else {
- val versionCodes =
- mapOf("armeabi-v7a" to 4, "arm64-v8a" to 4, "x86" to 4, "x86_64" to 4, "universal" to 4)
-
- variant.outputs
- .map { it as com.android.build.gradle.internal.api.ApkVariantOutputImpl }
- .forEach { output ->
- val abi = if (output.getFilter("ABI") != null)
- output.getFilter("ABI")
- else
- "universal"
-
- output.outputFileName = "v2rayNG_${variant.versionName}_${abi}.apk"
- if (versionCodes.containsKey(abi)) {
- output.versionCodeOverride =
- (1000000 * versionCodes[abi]!!).plus(variant.versionCode)
- } else {
- return@forEach
- }
- }
- }
- }
-
buildFeatures {
viewBinding = true
buildConfig = true
@@ -163,6 +115,28 @@ android {
}
+androidComponents {
+ onVariants { variant ->
+ val isFdroid = variant.productFlavors.any { it.second == "fdroid" }
+ variant.outputs.forEach { output ->
+ val abi = output.filters.find {
+ it.filterType == com.android.build.api.variant.FilterConfiguration.FilterType.ABI
+ }?.identifier ?: "universal"
+
+ if (isFdroid) {
+ val versionCodes = mapOf(
+ "armeabi-v7a" to 2, "arm64-v8a" to 1, "x86" to 4, "x86_64" to 3, "universal" to 0
+ )
+ versionCodes[abi]?.let { code ->
+ output.versionCode.set((100 * (output.versionCode.get() ?: 0) + code) + 5000000)
+ }
+ } else {
+ output.versionCode.set(1000000 * 4 + (output.versionCode.get() ?: 0))
+ }
+ }
+ }
+}
+
dependencies {
// Core Libraries
implementation(fileTree(mapOf("dir" to "libs", "include" to listOf("*.aar", "*.jar"))))
@@ -210,9 +184,6 @@ dependencies {
implementation(libs.work.runtime.ktx)
implementation(libs.work.multiprocess)
- // Multidex Support
- implementation(libs.multidex)
-
// Testing Libraries
testImplementation(libs.junit)
androidTestImplementation(libs.androidx.junit)
diff --git a/V2rayNG/app/src/main/java/xyz/zarazaex/olc/AngApplication.kt b/V2rayNG/app/src/main/java/xyz/zarazaex/olc/AngApplication.kt
index 20bb5f47..89640f8f 100644
--- a/V2rayNG/app/src/main/java/xyz/zarazaex/olc/AngApplication.kt
+++ b/V2rayNG/app/src/main/java/xyz/zarazaex/olc/AngApplication.kt
@@ -1,7 +1,7 @@
package xyz.zarazaex.olc
+import android.app.Application
import android.content.Context
-import androidx.multidex.MultiDexApplication
import androidx.work.Configuration
import androidx.work.WorkManager
import com.google.android.material.color.DynamicColors
@@ -9,7 +9,7 @@ import com.tencent.mmkv.MMKV
import xyz.zarazaex.olc.AppConfig.ANG_PACKAGE
import xyz.zarazaex.olc.handler.SettingsManager
-class AngApplication : MultiDexApplication() {
+class AngApplication : Application() {
companion object {
lateinit var application: AngApplication
}
diff --git a/V2rayNG/app/src/main/res/values-ar/strings.xml b/V2rayNG/app/src/main/res/values-ar/strings.xml
index 4a141936..b5f43943 100644
--- a/V2rayNG/app/src/main/res/values-ar/strings.xml
+++ b/V2rayNG/app/src/main/res/values-ar/strings.xml
@@ -417,4 +417,5 @@
- WebDAV
+ جارٍ التحديث…
diff --git a/V2rayNG/app/src/main/res/values-bn/strings.xml b/V2rayNG/app/src/main/res/values-bn/strings.xml
index 7155f7b4..44e0c023 100644
--- a/V2rayNG/app/src/main/res/values-bn/strings.xml
+++ b/V2rayNG/app/src/main/res/values-bn/strings.xml
@@ -423,4 +423,5 @@
- WebDAV
+ আপডেট হচ্ছে…
\ No newline at end of file
diff --git a/V2rayNG/app/src/main/res/values-bqi-rIR/strings.xml b/V2rayNG/app/src/main/res/values-bqi-rIR/strings.xml
index ef4c46f7..f8f1e262 100644
--- a/V2rayNG/app/src/main/res/values-bqi-rIR/strings.xml
+++ b/V2rayNG/app/src/main/res/values-bqi-rIR/strings.xml
@@ -433,4 +433,5 @@
- WebDAV
+ در حال بهروزرسانی…
diff --git a/V2rayNG/app/src/main/res/values-fa/strings.xml b/V2rayNG/app/src/main/res/values-fa/strings.xml
index ef2bbbc8..5b548397 100644
--- a/V2rayNG/app/src/main/res/values-fa/strings.xml
+++ b/V2rayNG/app/src/main/res/values-fa/strings.xml
@@ -432,4 +432,5 @@
- WebDAV
+ در حال بهروزرسانی…
diff --git a/V2rayNG/app/src/main/res/values-night/colors.xml b/V2rayNG/app/src/main/res/values-night/colors.xml
index 8436bc80..a09f369f 100644
--- a/V2rayNG/app/src/main/res/values-night/colors.xml
+++ b/V2rayNG/app/src/main/res/values-night/colors.xml
@@ -1,6 +1,6 @@
- @android:color/system_accent1_400
+ #90CAF9
#646464
#424242
@@ -9,15 +9,15 @@
#474747
#E0E0E0
- @android:color/system_accent1_400
+ #90CAF9
#FFFFFF
#6F3800
#FFE8D6
- @android:color/system_accent1_300
+ #64B5F6
#00382E
#005143
- @android:color/system_accent1_200
+ #BBDEFB
#FFB4AB
diff --git a/V2rayNG/app/src/main/res/values-vi/strings.xml b/V2rayNG/app/src/main/res/values-vi/strings.xml
index a1b255f1..f2059294 100644
--- a/V2rayNG/app/src/main/res/values-vi/strings.xml
+++ b/V2rayNG/app/src/main/res/values-vi/strings.xml
@@ -419,4 +419,5 @@
- WebDAV
+ Đang cập nhật…
diff --git a/V2rayNG/app/src/main/res/values-zh-rCN/strings.xml b/V2rayNG/app/src/main/res/values-zh-rCN/strings.xml
index 9259aad5..47a6a4ad 100644
--- a/V2rayNG/app/src/main/res/values-zh-rCN/strings.xml
+++ b/V2rayNG/app/src/main/res/values-zh-rCN/strings.xml
@@ -425,4 +425,5 @@
- WebDAV
+ 更新中…
diff --git a/V2rayNG/app/src/main/res/values-zh-rTW/strings.xml b/V2rayNG/app/src/main/res/values-zh-rTW/strings.xml
index 06029d6a..fd37d68c 100644
--- a/V2rayNG/app/src/main/res/values-zh-rTW/strings.xml
+++ b/V2rayNG/app/src/main/res/values-zh-rTW/strings.xml
@@ -425,4 +425,5 @@
- WebDAV
+ 更新中…
diff --git a/V2rayNG/app/src/main/res/values/colors.xml b/V2rayNG/app/src/main/res/values/colors.xml
index e1afd9f3..1d70108d 100644
--- a/V2rayNG/app/src/main/res/values/colors.xml
+++ b/V2rayNG/app/src/main/res/values/colors.xml
@@ -1,10 +1,10 @@
- @android:color/system_accent1_600
+ #1565C0
#FF0099
- @android:color/system_accent1_400
+ #1976D2
#FFFFFF
- @android:color/system_accent1_400
+ #1976D2
#9C9C9C
#E0E0E0
@color/md_theme_primary
@@ -14,14 +14,14 @@
#E0E0E0
#000000
- @android:color/system_accent1_400
+ #1976D2
#FFFFFF
#FFE8D6
#2B1700
- @android:color/system_accent1_600
+ #1565C0
#FFFFFF
- @android:color/system_accent1_200
+ #BBDEFB
#00201A
diff --git a/V2rayNG/build.gradle.kts b/V2rayNG/build.gradle.kts
index 9998df72..9693c98c 100644
--- a/V2rayNG/build.gradle.kts
+++ b/V2rayNG/build.gradle.kts
@@ -2,12 +2,4 @@
plugins {
alias(libs.plugins.android.application) apply false
alias(libs.plugins.android.library) apply false
- alias(libs.plugins.kotlin.android) apply false
}
-
-buildscript {
- dependencies {
- classpath(libs.gradle.license.plugin)
- }
-}
-
diff --git a/V2rayNG/gradle.properties b/V2rayNG/gradle.properties
index ae486e52..d50b44cf 100644
--- a/V2rayNG/gradle.properties
+++ b/V2rayNG/gradle.properties
@@ -15,20 +15,7 @@ org.gradle.jvmargs=-Xmx4096m -Dfile.encoding=UTF-8
# Android operating system, and which are packaged with your app's APK
# https://developer.android.com/topic/libraries/support-library/androidx-rn
android.useAndroidX=true
-# Kotlin code style for this project: "official" or "obsolete":
kotlin.code.style=official
-# Enables namespacing of each library's R class so that its R class includes only the
-# resources declared in the library itself and none from the library's dependencies,
-# thereby reducing the size of the R class for that library
android.nonTransitiveRClass=true
kotlin.incremental=true
-android.defaults.buildfeatures.resvalues=true
-android.sdk.defaultTargetSdkToCompileSdkIfUnset=false
-android.enableAppCompileTimeRClass=false
-android.usesSdkInManifest.disallowed=false
-android.uniquePackageNames=false
-android.dependency.useConstraints=true
-android.r8.strictFullModeForKeepRules=false
-android.r8.optimizedResourceShrinking=false
-android.builtInKotlin=false
-android.newDsl=false
\ No newline at end of file
+android.generateSyncIssueWhenLibraryConstraintsAreEnabled=false
\ No newline at end of file