Forcing an android app to quit when the 'home' button is clicked?

Terry Judd terry.judd at unimelb.edu.au
Mon Jan 18 21:54:45 EST 2016


Yeh - the back and menu keys trigger messages but not the home key. It
hadn¹t occurred to me to try suspendStack - I¹ll give that a whirl.

Thanks Ralph.

Terry...

On 19/01/2016 11:59 am, "use-livecode on behalf of Ralph DiMola"
<use-livecode-bounces at lists.runrev.com on behalf of
rdimola at evergreeninfo.net> wrote:

>That will work if the user hits the back key but if they hit the home
>button
>not so much. I leave my app open but I think remember some thread that
>mentioned the engine sends a message when the app is de-focused. Can't
>remember what it was. I believe it was suspendStack and resumeStack
>
>Ralph DiMola
>IT Director
>Evergreen Information Services
>rdimola at evergreeninfo.net
>
>
>-----Original Message-----
>From: use-livecode [mailto:use-livecode-bounces at lists.runrev.com] On
>Behalf
>Of Mark Schonewille
>Sent: Monday, January 18, 2016 7:46 PM
>To: How to use LiveCode
>Subject: Re: Forcing an android app to quit when the 'home' button is
>clicked?
>
>Terry,
>
>Reading the docs, I'd say the following should be possible:
>
>on backKey
>   quit
>end backKey
>
>Kind regards,
>
>Mark Schonewille
>http://economy-x-talk.com
>https://www.facebook.com/marksch
>
>Buy the most extensive book on the
>LiveCode language:
>http://livecodebeginner.economy-x-talk.com
>
>Op 1/18/2016 om 03:30 schreef Terry Judd:
>> On iOS the fact that a LC app routinely quits when the home button is
>clicked can be a pain but in the case of the app I'm currently developing
>I
>actually want this to occur. Anyway, I'm covered on iOS but how do I make
>the app quit when the user leaves it on an android device, or is this not
>possible?
>>
>> Terry.
>>
>> Terry Judd  | Senior Lecturer in Medical Education Department of
>> Medical Education<http://medicine.unimelb.edu.au/medical-education>
>> The University of Melbourne<http://www.unimelb.edu.au>
>> M: 0435 961 594  |  E:
>> terry.judd at unimelb.edu.au<mailto:tsj at unimelb.edu.au>
>> Publications<https://scholar.google.com.au/citations?user=XC5s6wwAAAAJ
>> &hl=en>
>>
>
>_______________________________________________
>use-livecode mailing list
>use-livecode at lists.runrev.com
>Please visit this url to subscribe, unsubscribe and manage your
>subscription
>preferences:
>http://lists.runrev.com/mailman/listinfo/use-livecode
>
>
>_______________________________________________
>use-livecode mailing list
>use-livecode at lists.runrev.com
>Please visit this url to subscribe, unsubscribe and manage your
>subscription preferences:
>http://lists.runrev.com/mailman/listinfo/use-livecode





More information about the use-livecode mailing list