Possible Duplicate:
How to detect when an Android app goes to the background and come back to the foreground
An Android app can have lots of actvities. I don't want to know when any old activity goes into the background, I want to know when any activity in the application goes into the background, and when any activity in the app comes into the foreground.
Do I have to handle onpause/onresume for each activity? Is there any easier way to do this?