From 329fb1681a6d8ea04f6e1105bfb8ee5a2d7fc580 Mon Sep 17 00:00:00 2001 From: qnblackcat Date: Sun, 14 Aug 2022 02:02:23 +0700 Subject: [PATCH] Skips content warning before playing *some videos - @PoomSmart --- Header.h | 4 ++++ uYouPlus.xm | 5 +++++ 2 files changed, 9 insertions(+) diff --git a/Header.h b/Header.h index 8e6718a..b776d49 100644 --- a/Header.h +++ b/Header.h @@ -9,6 +9,10 @@ @end // uYouPlus +@interface YTPlayabilityResolutionUserActionUIController : NSObject // Skips content warning before playing *some videos - @PoomSmart +- (void)confirmAlertDidPressConfirm; +@end + @interface YTMainAppControlsOverlayView : UIView @end diff --git a/uYouPlus.xm b/uYouPlus.xm index 3cc13e5..68d89be 100644 --- a/uYouPlus.xm +++ b/uYouPlus.xm @@ -80,6 +80,11 @@ BOOL hidePaidPromotionCard() { - (BOOL)canReorder { return YES; } %end +// Skips content warning before playing *some videos - @PoomSmart +%hook YTPlayabilityResolutionUserActionUIController +- (void)showConfirmAlert { [self confirmAlertDidPressConfirm]; } +%end + // YTMiniPlayerEnabler: https://github.com/level3tjg/YTMiniplayerEnabler/ %hook YTWatchMiniBarViewController - (void)updateMiniBarPlayerStateFromRenderer {