From 1613d561c19ccd8a07b579be3e7a5b2d1539863c Mon Sep 17 00:00:00 2001 From: arkon Date: Sat, 12 Mar 2022 16:45:36 -0500 Subject: [PATCH] Revert "Add shortcut to change app language in Android 13" This reverts commit 538478cac811655b077716383b1598db8de5e4dc. --- app/build.gradle.kts | 8 ++++---- .../ui/setting/SettingsGeneralController.kt | 13 ------------- app/src/main/res/values/strings.xml | 1 - buildSrc/src/main/kotlin/AndroidConfig.kt | 6 ++++++ 4 files changed, 10 insertions(+), 18 deletions(-) create mode 100644 buildSrc/src/main/kotlin/AndroidConfig.kt diff --git a/app/build.gradle.kts b/app/build.gradle.kts index 4ffc0bd04..bd067c946 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -17,13 +17,13 @@ shortcutHelper.setFilePath("./shortcuts.xml") val SUPPORTED_ABIS = setOf("armeabi-v7a", "arm64-v8a", "x86") android { - compileSdkPreview = "Tiramisu" - ndkVersion = "22.1.7171670" + compileSdk = AndroidConfig.compileSdk + ndkVersion = AndroidConfig.ndk defaultConfig { applicationId = "eu.kanade.tachiyomi" - minSdk = 23 - targetSdk = 29 + minSdk = AndroidConfig.minSdk + targetSdk = AndroidConfig.targetSdk versionCode = 76 versionName = "0.13.1" diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsGeneralController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsGeneralController.kt index aa780281c..368710872 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsGeneralController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsGeneralController.kt @@ -3,7 +3,6 @@ package eu.kanade.tachiyomi.ui.setting import android.content.Intent import android.os.Build import android.provider.Settings -import androidx.core.net.toUri import androidx.preference.PreferenceScreen import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.util.preference.bindTo @@ -55,17 +54,5 @@ class SettingsGeneralController : SettingsController() { } } } - if (Build.VERSION.CODENAME == "Tiramisu") { - preference { - key = "pref_manage_language" - titleRes = R.string.pref_app_language - onClick { - val intent = Intent(Settings.ACTION_APP_LOCALE_SETTINGS).apply { - data = "package:${context.packageName}".toUri() - } - startActivity(intent) - } - } - } } } diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index df28e93d3..608ad5cf1 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -178,7 +178,6 @@ Start screen Confirm exit Manage notifications - App language Security Require unlock diff --git a/buildSrc/src/main/kotlin/AndroidConfig.kt b/buildSrc/src/main/kotlin/AndroidConfig.kt new file mode 100644 index 000000000..19fce6f44 --- /dev/null +++ b/buildSrc/src/main/kotlin/AndroidConfig.kt @@ -0,0 +1,6 @@ +object AndroidConfig { + const val compileSdk = 31 + const val minSdk = 23 + const val targetSdk = 29 + const val ndk = "22.1.7171670" +}