Your thread will likely be killed in a bad way in onDestroy(). You should
therefore kill it yourself, for example in either onStop() or onDestroy().

Apps are killed, for the most part and from what I can tell when the back
button is used to exit the app, or the Home button is used and the system
needs the memory. The back button seems to cause the app to call onDestroy()
while the home button seems to cause the app to call onStop() and stay in
memory.

This is only what seems to happen most of the time, and isn't necessarily
what will happen in a given instance.

-----Original Message-----
From: g1bb [mailto:corymgibb...@gmail.com] 
Sent: Friday, January 23, 2009 8:16 AM
To: Android Developers
Subject: [android-developers] When does my thread die?


Hello,

I've created an app that functions as a countdown timer via a thread,
a wakelock, and a handler back to my activity. My question is, what
will cause my thread to die, or app to not be running in memory
anymore? I've had this happen once, and can't seem to recreate it
again.

Thanks in advance!


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to