From 4eea301aeabfd49306c867b0d827fbe2f7f0f13f Mon Sep 17 00:00:00 2001 From: foxster-mp4 Date: Tue, 23 May 2023 18:48:36 -0700 Subject: [PATCH 1/2] Fix #1107? --- uYouPlus.xm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/uYouPlus.xm b/uYouPlus.xm index 158f7ad..4a585a5 100644 --- a/uYouPlus.xm +++ b/uYouPlus.xm @@ -913,7 +913,7 @@ UIColor* raisedColor = [UIColor colorWithRed:0.035 green:0.035 blue:0.035 alpha: # pragma mark - ctor %ctor { // Load uYou first so its functions are available for hooks. - dlopen([[NSString stringWithFormat:@"%@/Frameworks/uYou.dylib", [[NSBundle mainBundle] bundlePath]] UTF8String], RTLD_LAZY); + // dlopen([[NSString stringWithFormat:@"%@/Frameworks/uYou.dylib", [[NSBundle mainBundle] bundlePath]] UTF8String], RTLD_LAZY); %init; if (@available(iOS 16, *)) { From a12b359ad78f99de231dff1fff9dc6489574002e Mon Sep 17 00:00:00 2001 From: foxster-mp4 Date: Tue, 30 May 2023 23:07:40 -0700 Subject: [PATCH 2/2] Fix stretched artwork in uYou's player view --- uYouPlus.xm | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/uYouPlus.xm b/uYouPlus.xm index 4a585a5..e7e0336 100644 --- a/uYouPlus.xm +++ b/uYouPlus.xm @@ -134,6 +134,21 @@ static BOOL oldDarkTheme() { } %end +// Fix streched artwork in uYou's player view +%hook ArtworkImageView +- (id)imageView { + UIImageView * imageView = %orig; + imageView.contentMode = UIViewContentModeScaleAspectFit; + // Make artwork a bit bigger + UIView *artworkImageView = imageView.superview; + if (artworkImageView != nil && !artworkImageView.translatesAutoresizingMaskIntoConstraints) { + [artworkImageView.leftAnchor constraintEqualToAnchor:artworkImageView.superview.leftAnchor constant:16].active = YES; + [artworkImageView.rightAnchor constraintEqualToAnchor:artworkImageView.superview.rightAnchor constant:-16].active = YES; + } + return imageView; +} +%end + # pragma mark - Tweaks // IAmYouTube - https://github.com/PoomSmart/IAmYouTube/ %hook YTVersionUtils