From 9b967177c51a93c5db3fe2079cc6581e5b065970 Mon Sep 17 00:00:00 2001
From: Zakhar Timoshenko <61558546+ztimms73@users.noreply.github.com>
Date: Sat, 12 Jun 2021 16:45:49 +0300
Subject: [PATCH] Added "Yotsuba" theme (#5290)
---
.../data/preference/PreferenceValues.kt | 1 +
.../ui/base/activity/BaseThemedActivity.kt | 1 +
.../ui/setting/SettingsGeneralController.kt | 6 ++++--
app/src/main/res/values/colors.xml | 5 +++++
app/src/main/res/values/strings.xml | 1 +
app/src/main/res/values/styles.xml | 4 ++++
app/src/main/res/values/themes.xml | 19 +++++++++++++++++++
7 files changed, 35 insertions(+), 2 deletions(-)
diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/preference/PreferenceValues.kt b/app/src/main/java/eu/kanade/tachiyomi/data/preference/PreferenceValues.kt
index b37445359..32a25818f 100644
--- a/app/src/main/java/eu/kanade/tachiyomi/data/preference/PreferenceValues.kt
+++ b/app/src/main/java/eu/kanade/tachiyomi/data/preference/PreferenceValues.kt
@@ -22,6 +22,7 @@ object PreferenceValues {
default,
blue,
strawberrydaiquiri,
+ yotsuba
}
// Keys are lowercase to match legacy string values
diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/base/activity/BaseThemedActivity.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/base/activity/BaseThemedActivity.kt
index 79b0012f4..f5e22cf68 100644
--- a/app/src/main/java/eu/kanade/tachiyomi/ui/base/activity/BaseThemedActivity.kt
+++ b/app/src/main/java/eu/kanade/tachiyomi/ui/base/activity/BaseThemedActivity.kt
@@ -41,6 +41,7 @@ abstract class BaseThemedActivity : AppCompatActivity() {
LightThemeVariant.default -> R.style.Theme_Tachiyomi_Light
LightThemeVariant.blue -> R.style.Theme_Tachiyomi_Light_Blue
LightThemeVariant.strawberrydaiquiri -> R.style.Theme_Tachiyomi_Light_StrawberryDaiquiri
+ LightThemeVariant.yotsuba -> R.style.Theme_Tachiyomi_Light_Yotsuba
}
}
setTheme(themeId)
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 b3bcd4e41..e5146198a 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
@@ -124,12 +124,14 @@ class SettingsGeneralController : SettingsController() {
entriesRes = arrayOf(
R.string.theme_light_default,
R.string.theme_light_blue,
- R.string.theme_light_strawberrydaiquiri
+ R.string.theme_light_strawberrydaiquiri,
+ R.string.theme_light_yotsuba
)
entryValues = arrayOf(
Values.LightThemeVariant.default.name,
Values.LightThemeVariant.blue.name,
- Values.LightThemeVariant.strawberrydaiquiri.name
+ Values.LightThemeVariant.strawberrydaiquiri.name,
+ Values.LightThemeVariant.yotsuba.name
)
defaultValue = Values.LightThemeVariant.default.name
summary = "%s"
diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml
index 98f4741de..f431270bc 100644
--- a/app/src/main/res/values/colors.xml
+++ b/app/src/main/res/values/colors.xml
@@ -33,6 +33,11 @@
#0AED4A65
#BFED4A65
+
+ #FC8C5C
+ #0AFC8C5C
+ #BFFC8C5C
+
#3399FF
@color/md_white_1000
diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml
index 6087f93e6..4b2f399c7 100644
--- a/app/src/main/res/values/strings.xml
+++ b/app/src/main/res/values/strings.xml
@@ -148,6 +148,7 @@
Default
Light Blue
Strawberry Daiquiri
+ Yotsuba
Dark theme
Default
Dark Blue
diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml
index 0d983e6d8..b424e0883 100644
--- a/app/src/main/res/values/styles.xml
+++ b/app/src/main/res/values/styles.xml
@@ -72,6 +72,10 @@
- @color/colorAccentStrawberry
+
+
diff --git a/app/src/main/res/values/themes.xml b/app/src/main/res/values/themes.xml
index fca875e08..a1b2de9f5 100644
--- a/app/src/main/res/values/themes.xml
+++ b/app/src/main/res/values/themes.xml
@@ -155,6 +155,25 @@
- @color/selectorColorStrawberry
+
+
+