• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Cancelling screensaver/sleep from an app
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Cancelling screensaver/sleep from an app


  • Subject: Re: Cancelling screensaver/sleep from an app
  • From: Ron Fleckner <email@hidden>
  • Date: Mon, 4 Aug 2008 22:53:49 +1000


On 04/08/2008, at 10:23 PM, Allison Newman wrote:


Hi everyone,

In my current app, I have long periods where the user may not interact with the app, but where the app display updates continuously, and the user continues to watch the app (think playing a movie, or something like that). How do I go about disabling the screensaver/sleep mode whilst the app is being used by the user?

Thanks in advance for any help.

Alli

Check the archives:<http://www.cocoabuilder.com/archive/message/cocoa/ 2007/4/28/182595>


But don't bother now because all you'll find there is the following:

- (void)preventSleep
{
keepAwakeTimer = [[NSTimer scheduledTimerWithTimeInterval:30
target:self selector:@selector(stayAwake:) userInfo:nil repeats: YES] retain];
}
- (void)stayAwake:(NSTimer *)sleepTimer
{
UpdateSystemActivity(OverallAct);// This is from Apple Tech Note QA1160:Preventing Sleep
}
_______________________________________________


Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Cancelling screensaver/sleep from an app (From: Allison Newman <email@hidden>)

  • Prev by Date: Re: Instance vars, local vars and speed
  • Next by Date: Re: Documentation
  • Previous by thread: Cancelling screensaver/sleep from an app
  • Next by thread: Documentation
  • Index(es):
    • Date
    • Thread