Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Does creating new android wakelock with tag return same wakelock every time?

Title can be enigmatic. My question is simple i create wakelock:

pwrMgr.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "wakelock1")

Then i do this again in another place, with same tag, do i get same wakelock with acquiration references?

like image 722
Tomasz Kryński Avatar asked Dec 08 '15 15:12

Tomasz Kryński


1 Answers

No, you do not. I wish that you did, as it would have simplified some scenarios. As the documentation indicates, it is solely for debugging purposes.

like image 62
CommonsWare Avatar answered Sep 28 '22 17:09

CommonsWare