Disable warning popup

This commit is contained in:
Bryce Hackel
2024-09-01 11:06:07 -07:00
parent 2134ae02d2
commit 810aca2f16
2 changed files with 17 additions and 5 deletions

View File

@@ -130,6 +130,10 @@ typedef NS_ENUM(NSUInteger, GestureSection) {
@property (nonatomic, assign, readwrite) BOOL enableSnapToChapter;
@end
// Hide YouTube Plus incompatibility warning popup - @bhackel
@interface HelperVC : UIViewController
@end
// Hide Autoplay Mini Preview - @bhackel
@interface YTAutonavPreviewView : UIView
@end

View File

@@ -110,12 +110,8 @@ BOOL isSelf() {
}
%end
# pragma mark - Hide SponsorBlock Button
// Hide SponsorBlock Button in navigation bar
%hook YTRightNavigationButtons
- (void)didMoveToWindow {
%orig;
}
- (void)layoutSubviews {
%orig;
if (IsEnabled(@"hideSponsorBlockButton_enabled")) {
@@ -174,6 +170,18 @@ BOOL isSelf() {
%end
%end
// Disable YouTube Plus incompatibility warning popup - @bhackel
%hook HelperVC
- (void)viewDidLoad {
%orig;
// Check if it responds to the selector riskButtonTapped
if ([self respondsToSelector:@selector(riskButtonTapped)]) {
// Call the selector riskButtonTapped
[self performSelector:@selector(riskButtonTapped)];
}
}
%end
// A/B flags
%hook YTColdConfig