Skip to content

Commit

Permalink
Merge pull request #529 from therealFoxster/main
Browse files Browse the repository at this point in the history
Update DontEatMyContent (1.0.0 -> 1.0.2)
  • Loading branch information
qnblackcat authored Oct 7, 2022
2 parents 7bafd0f + c39f2b5 commit b52aaac
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions uYouPlus.xm
Original file line number Diff line number Diff line change
Expand Up @@ -927,6 +927,7 @@ NSLayoutConstraint *widthConstraint, *heightConstraint, *centerXConstraint, *cen
- (void)didSwipeToExitFullscreen {
%orig; deactivate();
}
// Get video aspect ratio; doesn't work for some users; see -(void)resetForVideoWithAspectRatio:(double)
- (void)singleVideo:(id)arg1 aspectRatioDidChange:(CGFloat)arg2 {
aspectRatio = arg2;
if (aspectRatio == 0.0) {
Expand Down Expand Up @@ -958,6 +959,21 @@ NSLayoutConstraint *widthConstraint, *heightConstraint, *centerXConstraint, *cen
%orig(NO);
}
%end

%hook YTVideoZoomOverlayController
// Get video aspect ratio; fallback for -(void)singleVideo:(id)aspectRatioDidChange:(CGFloat)
- (void)resetForVideoWithAspectRatio:(double)arg1 {
aspectRatio = arg1;
%log;
if (aspectRatio == 0.0) {}
else if (aspectRatio < THRESHOLD) {
deactivate();
} else {
activate();
}
%orig(arg1);
}
%end
%end // gDontEatMyContent

// DontEatMycontent - detecting device model
Expand Down

0 comments on commit b52aaac

Please sign in to comment.