fix(YouTube - Player controls): Show player control buttons with A/B layout (#3901)

This commit is contained in:
LisoUseInAIKyrios
2024-11-12 10:07:32 +04:00
committed by GitHub
parent 53cb19f4a9
commit bb526bc00a
8 changed files with 106 additions and 5 deletions

View File

@ -53,4 +53,18 @@ public final class EnableDebuggingPatch {
return value;
}
/**
* Injection point.
*/
public static String isStringFeatureFlagEnabled(String value, long flag, String defaultValue) {
if (BaseSettings.DEBUG.get() && !defaultValue.equals(value)) {
if (featureFlags.putIfAbsent(flag, true) == null) {
Logger.printDebug(() -> " string feature is enabled: " + flag
+ " value: " + value + (defaultValue.isEmpty() ? "" : " default: " + defaultValue));
}
}
return value;
}
}

View File

@ -8,6 +8,7 @@ import app.revanced.extension.shared.Logger;
@SuppressWarnings("unused")
public class PlayerControlsPatch {
/**
* Injection point.
*/
@ -41,4 +42,11 @@ public class PlayerControlsPatch {
public static void fullscreenButtonVisibilityChanged(boolean isVisible) {
// Code added during patching.
}
/**
* Injection point.
*/
public static String getPlayerTopControlsLayoutResourceName(String original) {
return "default";
}
}