mirror of
https://github.com/revanced/revanced-integrations.git
synced 2025-01-22 01:37:31 +01:00
fix(YouTube - Disable auto captions): Do not break Shorts captions menu
This commit is contained in:
parent
d996d3832a
commit
0345a00d60
@ -1,6 +1,7 @@
|
|||||||
package app.revanced.integrations.youtube.patches;
|
package app.revanced.integrations.youtube.patches;
|
||||||
|
|
||||||
import app.revanced.integrations.youtube.settings.Settings;
|
import app.revanced.integrations.youtube.settings.Settings;
|
||||||
|
import app.revanced.integrations.youtube.shared.PlayerType;
|
||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
public class DisableAutoCaptionsPatch {
|
public class DisableAutoCaptionsPatch {
|
||||||
@ -11,7 +12,9 @@ public class DisableAutoCaptionsPatch {
|
|||||||
public static boolean captionsButtonDisabled;
|
public static boolean captionsButtonDisabled;
|
||||||
|
|
||||||
public static boolean autoCaptionsEnabled() {
|
public static boolean autoCaptionsEnabled() {
|
||||||
return Settings.AUTO_CAPTIONS.get();
|
return Settings.AUTO_CAPTIONS.get()
|
||||||
|
// Do not use auto captions for Shorts.
|
||||||
|
&& !PlayerType.getCurrent().isNoneHiddenOrSlidingMinimized();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user