This repository has been archived by the owner on Dec 11, 2024. It is now read-only.
forked from ReVanced/revanced-integrations
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(YouTube Music - Disable auto captions): Captions cannot be change…
…d when `Disable forced auto captions` is turned on
- Loading branch information
Showing
6 changed files
with
21 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
app/src/main/java/app/revanced/integrations/shared/patches/AutoCaptionsPatch.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package app.revanced.integrations.shared.patches; | ||
|
||
import app.revanced.integrations.shared.settings.BaseSettings; | ||
|
||
@SuppressWarnings("unused") | ||
public final class AutoCaptionsPatch { | ||
|
||
private static boolean captionsButtonStatus; | ||
|
||
public static boolean disableAutoCaptions() { | ||
return BaseSettings.DISABLE_AUTO_CAPTIONS.get() && | ||
!captionsButtonStatus; | ||
} | ||
|
||
public static void setCaptionsButtonStatus(boolean status) { | ||
captionsButtonStatus = status; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters