From 8f1d3c493d808b259bf4a8fa8374a0ade1ead78a Mon Sep 17 00:00:00 2001 From: LisoUseInAIKyrios <118716522+LisoUseInAIKyrios@users.noreply.github.com> Date: Sun, 19 Nov 2023 17:03:26 +0200 Subject: [PATCH] feat(YouTube):Add `Disable rolling number animations` patch (#519) --- .../patches/DisableRollingNumberAnimationsPatch.java | 12 ++++++++++++ .../revanced/integrations/settings/SettingsEnum.java | 1 + 2 files changed, 13 insertions(+) create mode 100644 app/src/main/java/app/revanced/integrations/patches/DisableRollingNumberAnimationsPatch.java diff --git a/app/src/main/java/app/revanced/integrations/patches/DisableRollingNumberAnimationsPatch.java b/app/src/main/java/app/revanced/integrations/patches/DisableRollingNumberAnimationsPatch.java new file mode 100644 index 0000000000..83a05a1c6f --- /dev/null +++ b/app/src/main/java/app/revanced/integrations/patches/DisableRollingNumberAnimationsPatch.java @@ -0,0 +1,12 @@ +package app.revanced.integrations.patches; + +import app.revanced.integrations.settings.SettingsEnum; + +public class DisableRollingNumberAnimationsPatch { + /** + * Injection point. + */ + public static boolean disableRollingNumberAnimations() { + return SettingsEnum.DISABLE_ROLLING_NUMBER_ANIMATIONS.getBoolean(); + } +} diff --git a/app/src/main/java/app/revanced/integrations/settings/SettingsEnum.java b/app/src/main/java/app/revanced/integrations/settings/SettingsEnum.java index fe011e4724..99f624215a 100644 --- a/app/src/main/java/app/revanced/integrations/settings/SettingsEnum.java +++ b/app/src/main/java/app/revanced/integrations/settings/SettingsEnum.java @@ -62,6 +62,7 @@ public enum SettingsEnum { CUSTOM_FILTER_STRINGS("revanced_custom_filter_strings", STRING, "", true, parents(CUSTOM_FILTER)), DISABLE_FULLSCREEN_AMBIENT_MODE("revanced_disable_fullscreen_ambient_mode", BOOLEAN, TRUE, true), DISABLE_RESUMING_SHORTS_PLAYER("revanced_disable_resuming_shorts_player", BOOLEAN, FALSE), + DISABLE_ROLLING_NUMBER_ANIMATIONS("revanced_disable_rolling_number_animations", BOOLEAN, FALSE), DISABLE_SUGGESTED_VIDEO_END_SCREEN("revanced_disable_suggested_video_end_screen", BOOLEAN, TRUE), GRADIENT_LOADING_SCREEN("revanced_gradient_loading_screen", BOOLEAN, FALSE), HIDE_ALBUM_CARDS("revanced_hide_album_cards", BOOLEAN, FALSE, true),