From 237c3d1c44503c9be4762b43a841b011f5faeebb Mon Sep 17 00:00:00 2001 From: "Jay Freeman (saurik)" Date: Sat, 17 May 2014 15:48:28 -0700 Subject: [PATCH] If using setRootViewController: don't addSubview:. --- MobileCydia.mm | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/MobileCydia.mm b/MobileCydia.mm index 8f440f5a..32031c46 100644 --- a/MobileCydia.mm +++ b/MobileCydia.mm @@ -8901,10 +8901,13 @@ static void HomeControllerReachabilityCallback(SCNetworkReachabilityRef reachabi if (emulated_ == nil) return; - [window_ addSubview:[tabbar_ view]]; if ([window_ respondsToSelector:@selector(setRootViewController:)]) [window_ setRootViewController:tabbar_]; - [[emulated_ view] removeFromSuperview]; + else { + [window_ addSubview:[tabbar_ view]]; + [[emulated_ view] removeFromSuperview]; + } + emulated_ = nil; [window_ setUserInteractionEnabled:YES]; } @@ -9594,9 +9597,10 @@ _trace(); [self setupViewControllers]; emulated_ = [[[CydiaLoadingViewController alloc] init] autorelease]; - [window_ addSubview:[emulated_ view]]; if ([window_ respondsToSelector:@selector(setRootViewController:)]) [window_ setRootViewController:emulated_]; + else + [window_ addSubview:[emulated_ view]]; [self performSelector:@selector(loadData) withObject:nil afterDelay:0]; _trace(); -- 2.50.0