Major refactor: split codebase into multiple files
Now for the fun part: will this compile?
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
#import "../Tweaks/YouTubeHeader/YTPlayerOverlayProvider.h"
|
||||
#import "../Tweaks/YouTubeHeader/YTPlayerOverlay.h"
|
||||
#import "uYouPlus.h"
|
||||
|
||||
// YTNoPaidPromo: https://github.com/PoomSmart/YTNoPaidPromo
|
||||
%hook YTMainAppVideoPlayerOverlayViewController
|
||||
- (void)setPaidContentWithPlayerData:(id)data {
|
||||
if (IS_ENABLED(@"hidePaidPromotionCard_enabled")) {}
|
||||
else { return %orig; }
|
||||
}
|
||||
- (void)playerOverlayProvider:(YTPlayerOverlayProvider *)provider didInsertPlayerOverlay:(YTPlayerOverlay *)overlay {
|
||||
if ([[overlay overlayIdentifier] isEqualToString:@"player_overlay_paid_content"] && IS_ENABLED(@"hidePaidPromotionCard_enabled")) return;
|
||||
%orig;
|
||||
}
|
||||
%end
|
||||
|
||||
%hook YTInlineMutedPlaybackPlayerOverlayViewController
|
||||
- (void)setPaidContentWithPlayerData:(id)data {
|
||||
if (IS_ENABLED(@"hidePaidPromotionCard_enabled")) {}
|
||||
else { return %orig; }
|
||||
}
|
||||
%end
|
||||
Reference in New Issue
Block a user