Skip to content

Commit

Permalink
support YT v17.25.1
Browse files Browse the repository at this point in the history
  • Loading branch information
qnblackcat committed Jun 27, 2022
1 parent b2b1430 commit 9145301
Showing 1 changed file with 13 additions and 22 deletions.
35 changes: 13 additions & 22 deletions uYouPlus.xm
Original file line number Diff line number Diff line change
Expand Up @@ -232,11 +232,15 @@ BOOL ytMiniPlayer() {
- (void)showSurveyWithRenderer:(id)arg1 surveyParentResponder:(id)arg2 {}
%end

// Enable Shorts scroll bar - level3tjg - https://reddit.com/r/jailbreak/comments/v29yvk/_/iasl1l0/
// Enable Shorts scroll bar - @level3tjg - https://reddit.com/r/jailbreak/comments/v29yvk/_/iasl1l0/
%hook YTReelPlayerViewControllerSub
- (BOOL)shouldEnablePlayerBar { return YES; }
%end

%hook YTReelPlayerViewController
- (BOOL)shouldEnablePlayerBar { return YES; }
%end

// Hide the download playlist button of uYou cuz it's broken ?!
// %hook YTPlaylistHeaderViewController
// - (void)viewDidLoad {
Expand All @@ -253,7 +257,7 @@ BOOL ytMiniPlayer() {
}
%end

// Hide YouTube Shorts banner in Home page? - MiRO92 - YTNoShorts: https://github.com/MiRO92/YTNoShorts
// Hide YouTube Shorts banner in Home page? - @MiRO92 - YTNoShorts: https://github.com/MiRO92/YTNoShorts
%hook YTAsyncCollectionView
- (id)cellForItemAtIndexPath:(NSIndexPath *)indexPath {
UICollectionViewCell *cell = %orig;
Expand Down Expand Up @@ -344,6 +348,12 @@ BOOL ytMiniPlayer() {
return %orig;
}
- (UIColor *)brandBackgroundSecondary {
if (self.pageStyle == 1) {
return [[UIColor blackColor] colorWithAlphaComponent:0.88];
}
return %orig;
}
- (UIColor *)raisedBackground {
if (self.pageStyle == 1) {
return [UIColor blackColor];
}
Expand Down Expand Up @@ -373,15 +383,6 @@ BOOL ytMiniPlayer() {
}
%end

// %hook YTInnerTubeCollectionViewController
// - (UIColor *)backgroundColor:(NSInteger)pageStyle {
// if (pageStyle == 1) {
// return [UIColor blackColor];
// }
// return %orig;
// }
// %end

// Explore
%hook ASScrollView
- (void)didMoveToWindow {
Expand Down Expand Up @@ -421,16 +422,6 @@ BOOL ytMiniPlayer() {
}
%end

// YT Miniplayer
%hook YTWatchMiniBarView
- (void)setBackgroundColor:(UIColor *)color {
if (isDarkMode()) {
return %orig([[UIColor blackColor] colorWithAlphaComponent:0.88]);
}
return %orig;
}
%end

// Search View
%hook YTSearchBarView
- (void)setBackgroundColor:(UIColor *)color {
Expand Down Expand Up @@ -522,7 +513,7 @@ BOOL ytMiniPlayer() {
}
%end

// Nasty stuff :/
// Others
%hook _ASDisplayView
- (void)didMoveToWindow {
%orig;
Expand Down

0 comments on commit 9145301

Please sign in to comment.