From: Jay Freeman (saurik) Date: Sat, 31 Mar 2012 20:07:26 +0000 (-0700) Subject: Move setIdleTimerDisabled: mechanism to {,un}lockSuspend:. X-Git-Tag: v1.1.6~1 X-Git-Url: https://git.saurik.com/cydia.git/commitdiff_plain/26c8a4c8c1b07a770ed97ba25af5065fe74433f2?ds=inline Move setIdleTimerDisabled: mechanism to {,un}lockSuspend:. --- diff --git a/MobileCydia.mm b/MobileCydia.mm index bd18af14..487623a6 100644 --- a/MobileCydia.mm +++ b/MobileCydia.mm @@ -9350,11 +9350,15 @@ static void HomeControllerReachabilityCallback(SCNetworkReachabilityRef reachabi if (locked_++ == 0) { if ($SBSSetInterceptsMenuButtonForever != NULL) (*$SBSSetInterceptsMenuButtonForever)(true); + + [self setIdleTimerDisabled:YES]; } } - (void) unlockSuspend { if (--locked_ == 0) { + [self setIdleTimerDisabled:NO]; + if ($SBSSetInterceptsMenuButtonForever != NULL) (*$SBSSetInterceptsMenuButtonForever)(false); } @@ -10099,8 +10103,6 @@ static void HomeControllerReachabilityCallback(SCNetworkReachabilityRef reachabi } - (void) stash { - [self setIdleTimerDisabled:YES]; - [[UIApplication sharedApplication] setStatusBarStyle:UIStatusBarStyleBlackOpaque]; UpdateExternalStatus(1); [self yieldToSelector:@selector(system:) withObject:@"/usr/libexec/cydia/free.sh"];