disable double tap to skip

This commit is contained in:
qnblackcat
2023-04-05 23:22:04 +07:00
parent 49aad95daa
commit c1567fa58e
2 changed files with 28 additions and 20 deletions
+10
View File
@@ -69,6 +69,16 @@ extern NSBundle *uYouPlusBundle();
} }
settingItemId:0], settingItemId:0],
[YTSettingsSectionItemClass switchItemWithTitle:LOC(@"DISABLE_DOUBLE_TAP_TO_SEEK")
titleDescription:LOC(@"DISABLE_DOUBLE_TAP_TO_SEEK_DESC")
accessibilityIdentifier:nil
switchOn:IsEnabled(@"doubleTapToSeek_disabled")
switchBlock:^BOOL (YTSettingsCell *cell, BOOL enabled) {
[[NSUserDefaults standardUserDefaults] setBool:enabled forKey:@"doubleTapToSeek_disabled"];
return YES;
}
settingItemId:0],
[YTSettingsSectionItemClass switchItemWithTitle:LOC(@"SNAP_TO_CHAPTER") [YTSettingsSectionItemClass switchItemWithTitle:LOC(@"SNAP_TO_CHAPTER")
titleDescription:LOC(@"SNAP_TO_CHAPTER_DESC") titleDescription:LOC(@"SNAP_TO_CHAPTER_DESC")
accessibilityIdentifier:nil accessibilityIdentifier:nil
+18 -20
View File
@@ -870,6 +870,12 @@ void DEMC_centerRenderingView() {
%end %end
%end %end
%hook YTDoubleTapToSeekController
- (void)enableDoubleTapToSeek:(BOOL)arg1 {
return IsEnabled(@"doubleTapToSeek_disabled") ? %orig(NO) : %orig;
}
%end
// Video Controls Overlay Options // Video Controls Overlay Options
// Hide CC / Autoplay switch // Hide CC / Autoplay switch
%hook YTMainAppControlsOverlayView %hook YTMainAppControlsOverlayView
@@ -1298,14 +1304,6 @@ UIColor* raisedColor = [UIColor colorWithRed:0.035 green:0.035 blue:0.035 alpha:
%hook YTHeaderContentComboView %hook YTHeaderContentComboView
- (void)setFeedHeaderScrollMode:(int)arg1 { %orig(0); } - (void)setFeedHeaderScrollMode:(int)arg1 { %orig(0); }
%end %end
// Hide the chip bar under the video player?
// %hook YTChipCloudCell //
// - (void)didMoveToWindow {
// %orig;
// self.hidden = YES;
// }
// %end
%end %end
%group giPhoneLayout %group giPhoneLayout
@@ -1345,40 +1343,40 @@ UIColor* raisedColor = [UIColor colorWithRed:0.035 green:0.035 blue:0.035 alpha:
%init; %init;
if (@available(iOS 16, *)) { if (@available(iOS 16, *)) {
%init(iOS16); %init(iOS16);
} }
if (IsEnabled(@"reExplore_enabled")) { if (IsEnabled(@"reExplore_enabled")) {
%init(gReExplore); %init(gReExplore);
} }
if (IsEnabled(@"bigYTMiniPlayer_enabled") && (UIDevice.currentDevice.userInterfaceIdiom != UIUserInterfaceIdiomPad)) { if (IsEnabled(@"bigYTMiniPlayer_enabled") && (UIDevice.currentDevice.userInterfaceIdiom != UIUserInterfaceIdiomPad)) {
%init(Main); %init(Main);
} }
if (IsEnabled(@"dontEatMyContent_enabled") && DEMC_deviceIsSupported()) { if (IsEnabled(@"dontEatMyContent_enabled") && DEMC_deviceIsSupported()) {
%init(gDontEatMyContent); %init(gDontEatMyContent);
} }
if (IsEnabled(@"hidePreviousAndNextButton_enabled")) { if (IsEnabled(@"hidePreviousAndNextButton_enabled")) {
%init(gHidePreviousAndNextButton); %init(gHidePreviousAndNextButton);
} }
if (IsEnabled(@"replacePreviousAndNextButton_enabled")) { if (IsEnabled(@"replacePreviousAndNextButton_enabled")) {
%init(gReplacePreviousAndNextButton); %init(gReplacePreviousAndNextButton);
} }
if (oledDarkTheme()) { if (oledDarkTheme()) {
%init(gOLED); %init(gOLED);
} }
if (oldDarkTheme()) { if (oldDarkTheme()) {
%init(gOldDarkTheme) %init(gOldDarkTheme)
} }
if (IsEnabled(@"oledKeyBoard_enabled")) { if (IsEnabled(@"oledKeyBoard_enabled")) {
%init(gOLEDKB); %init(gOLEDKB);
} }
if (IsEnabled(@"disableHints_enabled")) { if (IsEnabled(@"disableHints_enabled")) {
%init(gDisableHints); %init(gDisableHints);
} }
if (IsEnabled(@"hideChipBar_enabled")) { if (IsEnabled(@"hideChipBar_enabled")) {
%init(gHideChipBar); %init(gHideChipBar);
} }
if (IsEnabled(@"iPhoneLayout_enabled") && (UIDevice.currentDevice.userInterfaceIdiom == UIUserInterfaceIdiomPad)) { if (IsEnabled(@"iPhoneLayout_enabled") && (UIDevice.currentDevice.userInterfaceIdiom == UIUserInterfaceIdiomPad)) {
%init(giPhoneLayout); %init(giPhoneLayout);
} }
if (IsEnabled(@"stockVolumeHUD_enabled")) { if (IsEnabled(@"stockVolumeHUD_enabled")) {
%init(gStockVolumeHUD); %init(gStockVolumeHUD);