1. Download our Official Android App: Forums for Android!

Apps Stopping phone from sleeping

Discussion in 'Android Development' started by ophanin, Sep 9, 2010.

  1. ophanin

    ophanin Newbie
    Thread Starter
    Rank:
    None
    Points:
    35
    Posts:
    20
    Joined:
    Jun 14, 2010

    Jun 14, 2010
    20
    0
    35
    Graduate Student
    Rochester, NY
    Hi all,

    This is probably a simple question, but I'm coming up with nothing substancial on searches. Is there a good way to stop the phone from sleeping for an application? I was investigating using the PowerManager class, but I am wondering if there is an easier way out there.
     

    Advertisement

  2. speedracer

    speedracer Lurker
    Rank:
    None
    Points:
    5
    Posts:
    5
    Joined:
    Nov 13, 2009

    Nov 13, 2009
    5
    0
    5
    I'd say with some certainty that PowerManager/WakeLock is your best option. There are some sample code out there to help you, just google it.
     

Share This Page

Loading...