Getting rid of the first object

This commit is contained in:
Dan
2024-03-10 06:35:48 +03:00
committed by GitHub
parent c3cc0b4286
commit e5894e7291
+2 -2
View File
@@ -809,7 +809,7 @@ static BOOL isOverlayShown = YES;
if (ytlBool(@"pinchToFullscreenShorts") && [self.playerViewDelegate.parentViewController isKindOfClass:NSClassFromString(@"YTShortsPlayerViewController")]) { if (ytlBool(@"pinchToFullscreenShorts") && [self.playerViewDelegate.parentViewController isKindOfClass:NSClassFromString(@"YTShortsPlayerViewController")]) {
YTShortsPlayerViewController *shortsPlayerVC = (YTShortsPlayerViewController *)self.playerViewDelegate.parentViewController; YTShortsPlayerViewController *shortsPlayerVC = (YTShortsPlayerViewController *)self.playerViewDelegate.parentViewController;
YTReelContentView *contentView = (YTReelContentView *)shortsPlayerVC.view; YTReelContentView *contentView = (YTReelContentView *)shortsPlayerVC.view;
UIWindow *mainWindow = [UIApplication sharedApplication].windows.firstObject; UIWindow *mainWindow = [[[UIApplication sharedApplication] delegate] window];
YTAppViewController *appVC = (YTAppViewController *)mainWindow.rootViewController; YTAppViewController *appVC = (YTAppViewController *)mainWindow.rootViewController;
if (gesture.scale > 1) { if (gesture.scale > 1) {
@@ -853,7 +853,7 @@ static BOOL isOverlayShown = YES;
[[%c(YTToastResponderEvent) eventWithMessage:LOC(@"ShortsModeTurnedOff") firstResponder:[%c(YTUIUtils) topViewControllerForPresenting]] send]; [[%c(YTToastResponderEvent) eventWithMessage:LOC(@"ShortsModeTurnedOff") firstResponder:[%c(YTUIUtils) topViewControllerForPresenting]] send];
UIWindow *mainWindow = [UIApplication sharedApplication].windows.firstObject; UIWindow *mainWindow = [[[UIApplication sharedApplication] delegate] window];
YTAppViewController *appVC = (YTAppViewController *)mainWindow.rootViewController; YTAppViewController *appVC = (YTAppViewController *)mainWindow.rootViewController;
[appVC performSelector:@selector(showPivotBar) withObject:nil afterDelay:1.0]; [appVC performSelector:@selector(showPivotBar) withObject:nil afterDelay:1.0];
} }