mirror of
https://github.com/inotia00/revanced-patches.git
synced 2025-04-29 22:24:31 +02:00
fix(YouTube - Shorts components): Pause
option of Change Shorts repeat state
not working (20.09+)
This commit is contained in:
parent
0bfabbc384
commit
a764e3aea3
@ -101,7 +101,10 @@ public class ShortsRepeatStatePatch {
|
||||
: "Changing Shorts repeat behavior from: " + name + " to: " + overrideBehavior.name();
|
||||
});
|
||||
|
||||
return overrideBehavior;
|
||||
// For some reason, in YouTube 20.09+, 'UNKNOWN' functions as 'Pause'.
|
||||
return ExtendedUtils.IS_20_09_OR_GREATER && behavior == ShortsLoopBehavior.END_SCREEN
|
||||
? ShortsLoopBehavior.UNKNOWN.ytEnumValue
|
||||
: overrideBehavior;
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
Logger.printException(() -> "changeShortsRepeatBehavior failure", ex);
|
||||
|
@ -39,6 +39,7 @@ public class ExtendedUtils extends PackageUtils {
|
||||
public static final boolean IS_19_28_OR_GREATER = getAppVersionName().compareTo("19.28.00") >= 0;
|
||||
public static final boolean IS_19_29_OR_GREATER = getAppVersionName().compareTo("19.29.00") >= 0;
|
||||
public static final boolean IS_19_34_OR_GREATER = getAppVersionName().compareTo("19.34.00") >= 0;
|
||||
public static final boolean IS_20_09_OR_GREATER = getAppVersionName().compareTo("20.09.00") >= 0;
|
||||
|
||||
public static int validateValue(IntegerSetting settings, int min, int max, String message) {
|
||||
int value = settings.get();
|
||||
|
Loading…
x
Reference in New Issue
Block a user