From a6e6d0e4917691dc96a4203bffd162fd76e65324 Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Sun, 22 Sep 2019 20:33:38 -0700 Subject: [PATCH] Restore focus on the correct app after closing the stream --- Limelight/ViewControllers/MainFrameViewController.m | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Limelight/ViewControllers/MainFrameViewController.m b/Limelight/ViewControllers/MainFrameViewController.m index 8482ab7d..efdd14ae 100644 --- a/Limelight/ViewControllers/MainFrameViewController.m +++ b/Limelight/ViewControllers/MainFrameViewController.m @@ -714,6 +714,10 @@ static NSMutableSet* hostList; // if the user drags all the way off the screen opposite the settings pane. self.revealViewController.bounceBackOnOverdraw = NO; #else + // Restore focus on the selected app on view controller pop navigation + self.restoresFocusAfterTransition = NO; + self.collectionView.remembersLastFocusedIndexPath = YES; + _menuRecognizer = [[UITapGestureRecognizer alloc] init]; [_menuRecognizer addTarget:self action: @selector(showHostSelectionView)]; _menuRecognizer.allowedPressTypes = [[NSArray alloc] initWithObjects:[NSNumber numberWithLong:UIPressTypeMenu], nil];