suspend/resume messages on Android?
terry.judd at unimelb.edu.au
Tue May 7 17:35:23 EDT 2013
On 08/05/2013, at 4:35 AM, "J. Landman Gay" <jacque at hyperactivesw.com> wrote:
> On 5/7/13 1:28 AM, Terry Judd wrote:
>> I've been going back through the list archives and I'm still not
>> exactly sure how you're supposed to deal with 'suspending' and
>> 'resuming' an Android app. It seems that in most cases, and unlike in
>> iOS, when you switch away from an Android app and then return to it
>> it will be in the same state that you left it. That's a good thing,
>> but I'd still like to receive some sort of message or notification
>> when the user leaves and returns to the app as I potentially need to
>> do some housekeeping depending on the interval between the leaving
>> and the return. Is there a preferred way of doing this?
> There is always a "shutdown" message sent when the user leaves the app, even if the OS keeps it available in the background.
> Android manages app availability on its own. Usually if you leave an app and come back immediately or soon after, it will still be held in RAM and it will resume where it left off. But you can't rely on that. Android will wipe it from RAM whenever it needs more room, and that can be at any time. So it is best to always assume the app will be starting from scratch the next time it opens.
Thanks Jacque - looks like this is going to be more complicated than I'd like. If only the resume message was also sent.
> Jacqueline Landman Gay | jacque at hyperactivesw.com
> HyperActive Software | http://www.hyperactivesw.com
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
More information about the Use-livecode