android.app.Application subclass, onTerminate is not being called

Posted by synic on Stack Overflow See other posts from Stack Overflow or by synic
Published on 2010-03-19T23:04:19Z Indexed on 2010/03/19 23:11 UTC
Read the original article Hit count: 559

Filed under:

From the documentation for android.app.Application:

"Base class for those who need to maintain global application state"

I am using my own subclass to maintain an object that I'm using to query a server. Also from the documentation:

"onTerminate() Called when the application is stopping."

However, onTerminate() in my class is never called. I press the back button while viewing my main activity, and everything seems to shut down. My main Activity's onDestroy() method is called and isFinishing() returns true, but my android.app.Application's onTerminate() method is never called.

Why is this? What am I missing? Is there something that is keeping it open?

© Stack Overflow or respective owner

Related posts about android