feat: `disable-auto-captions` patch (#133)

This commit is contained in:
OxrxL 2022-09-15 03:00:15 +02:00 committed by GitHub
parent c82a85ba37
commit 233d332473
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 5 deletions

View File

@ -2,9 +2,11 @@ package app.revanced.integrations.patches;
import app.revanced.integrations.settings.SettingsEnum;
public class ForceDisableCaptionsPatch {
public static boolean captionsEnabled() {
public class DisableAutoCaptionsPatch {
public static boolean captionsButtonDisabled;
public static boolean autoCaptionsEnabled() {
return SettingsEnum.CAPTIONS_ENABLED.getBoolean();
}

View File

@ -60,8 +60,7 @@ public enum SettingsEnum {
FULLSCREEN_PANELS_SHOWN("revanced_fullscreen_panels_enabled", false, ReturnType.BOOLEAN), //ToDo: Add to prefs
//Misc. Settings
//ToDo: Not used atm, Patch missing
CAPTIONS_ENABLED("revanced_pref_captions", false, ReturnType.BOOLEAN),
CAPTIONS_ENABLED("revanced_autocaptions_enabled", false, ReturnType.BOOLEAN, false),
PREFERRED_AUTO_REPEAT("revanced_pref_auto_repeat", false, ReturnType.BOOLEAN),
USE_HDR_AUTO_BRIGHTNESS("revanced_pref_hdr_autobrightness", true, ReturnType.BOOLEAN),
TAP_SEEKING_ENABLED("revanced_enable_tap_seeking", true, ReturnType.BOOLEAN),