Workaround for iOS 15 uYou settings bug (#10)

This commit is contained in:
level3tjg
2022-08-27 02:49:20 -04:00
parent 6418f3daeb
commit 11ddcd421d
2 changed files with 13 additions and 0 deletions
+10
View File
@@ -222,6 +222,16 @@ BOOL hidePaidPromotionCard() {
}
%end
// Workaround for qnblackcat/uYouPlus#10
%hook boolSettingsVC
- (instancetype)initWithTitle:(NSString *)title sections:(NSArray *)sections footer:(NSString *)footer {
if (@available(iOS 15, *))
if (![self valueForKey:@"_lastNotifiedTraitCollection"])
[self setValue:[UITraitCollection currentTraitCollection] forKey:@"_lastNotifiedTraitCollection"];
return %orig;
}
%end
// YTClassicVideoQuality: https://github.com/PoomSmart/YTClassicVideoQuality
%hook YTVideoQualitySwitchControllerFactory
- (id)videoQualitySwitchControllerWithParentResponder:(id)responder {