mirror of
https://github.com/revanced/revanced-integrations.git
synced 2024-11-08 05:07:02 +01:00
fix(YouTube - Settings): Use same background color for about screen if Theme patch is not included
This commit is contained in:
parent
5ed4292e2e
commit
4164ed3486
@ -16,6 +16,7 @@ public class ThemeHelper {
|
|||||||
/**
|
/**
|
||||||
* Injection point.
|
* Injection point.
|
||||||
*/
|
*/
|
||||||
|
@SuppressWarnings("unused")
|
||||||
public static void setTheme(Enum<?> value) {
|
public static void setTheme(Enum<?> value) {
|
||||||
final int newOrdinalValue = value.ordinal();
|
final int newOrdinalValue = value.ordinal();
|
||||||
if (themeValue != newOrdinalValue) {
|
if (themeValue != newOrdinalValue) {
|
||||||
@ -40,12 +41,12 @@ public class ThemeHelper {
|
|||||||
*/
|
*/
|
||||||
private static String darkThemeResourceName() {
|
private static String darkThemeResourceName() {
|
||||||
// Value is changed by Theme patch, if included.
|
// Value is changed by Theme patch, if included.
|
||||||
return "@android:color/black";
|
return "@color/yt_black3";
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return The dark theme color as specified by the Theme patch (if included),
|
* @return The dark theme color as specified by the Theme patch (if included),
|
||||||
* or the Android color of black.
|
* or the dark mode background color unpatched YT uses.
|
||||||
*/
|
*/
|
||||||
public static int getDarkThemeColor() {
|
public static int getDarkThemeColor() {
|
||||||
if (darkThemeColor == null) {
|
if (darkThemeColor == null) {
|
||||||
@ -59,12 +60,12 @@ public class ThemeHelper {
|
|||||||
*/
|
*/
|
||||||
private static String lightThemeResourceName() {
|
private static String lightThemeResourceName() {
|
||||||
// Value is changed by Theme patch, if included.
|
// Value is changed by Theme patch, if included.
|
||||||
return "@android:color/white";
|
return "@color/yt_white1";
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return The light theme color as specified by the Theme patch (if included),
|
* @return The light theme color as specified by the Theme patch (if included),
|
||||||
* or the Android color of white.
|
* or the non dark mode background color unpatched YT uses.
|
||||||
*/
|
*/
|
||||||
public static int getLightThemeColor() {
|
public static int getLightThemeColor() {
|
||||||
if (lightThemeColor == null) {
|
if (lightThemeColor == null) {
|
||||||
|
Loading…
Reference in New Issue
Block a user