Translate

Sunday, March 18, 2012

device disable Sleep and enable sleep

disable sleep :

UIApplication *thisApp = [UIApplication sharedApplication];
    thisApp.idleTimerDisabled = YES;

enable sleep :

UIApplication *thisApp = [UIApplication sharedApplication];
    thisApp.idleTimerDisabled = NO;

1 comment: