I am setting a wake lock using wl.acquire()
. This works fine. I need that wake lock as long as my application lives, so calling release()
can only be done when the application is left.
Do I have to call release()
somewhere? For example in onStop()
? I would say no, but I am not sure.
Beside the others useful answers you already received, I just found this interesting answer about how to force screen on, maybe you'll find it useful too, if you don't really need a wake lock.