Question

I am currently working on an app that check for GPS data every X mins/seconds. I use the "pause" event to stop it while the app is in background and resume it with "resume" event. No problem there.

The problem is when you lock the device: it fires the pause event but won't resume on unlock. Is it a known bug? Is there another event I should know of? Thanks!

Was it helpful?

Solution

Listen for the "resumed" (with a D at the end) event instead of "resume".

You will get "resumed" for app relaunch (along with the "resume" event), but also for unlock, dismiss of a notification, dismiss the multitasking bar, etc.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top