Getting into LiveCode for iOS? Ask your questions here.
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
jmburnod
- VIP Livecode Opensource Backer

- Posts: 2729
- Joined: Sat Dec 22, 2007 5:35 pm
-
Contact:
Post
by jmburnod » Thu Oct 04, 2012 8:21 pm
Hi All,
To quit my app the user must click two times on a btw "quit".
I added a "shutdownRequest" but that is the same behavior.
What is the trick ?
Code: Select all
on debQuitter
ExpCurJoueur
ExpPref
wait 1 milliseconds
--lock messages
quit
if it is "Yes" then
quit
end if
end debQuitter
on shutdownRequest
answer question "Are you sure you want to quit?" with "Yes" or "No"
if it is "Yes" then pass shutdownRequest
end shutdownRequest
on ExpCurJoueur
put "DernierJoueur.txt" into tFile
put unPathDansNec2() & tFile into tPath
put gLecurJoueur into url("file:" & tPath)
end ExpCurJoueur
on ExpPref
put UnPathDansNec2(UnInscrit) & gLeCurjoueur & "/" & "Prefs.txt" into tpathFi
put gLesCurPrefStack into url ("file:"&tpathFi)
end ExpPref
https://alternatic.ch
-
bn
- VIP Livecode Opensource Backer

- Posts: 4168
- Joined: Sun Jan 07, 2007 9:12 pm
Post
by bn » Thu Oct 04, 2012 8:52 pm
Hi Jean-Marc,
on iOS you don't let the user quit an app. He just presses the home button and the app closes. No "do you really want to quit?" dialog. It is not how apps in iOS work.
Once the user presses the "home" button you get the "shutDown" message and you do your saving then.
Kind regards
Bernd
-
jmburnod
- VIP Livecode Opensource Backer

- Posts: 2729
- Joined: Sat Dec 22, 2007 5:35 pm
-
Contact:
Post
by jmburnod » Thu Oct 04, 2012 9:15 pm
Hi Bernd,
Thanks a lot. I believed that I became crazy
But it means that certain persons with whom I work cannot leave the application without the help of someone
Kind regards
Jean-Marc
https://alternatic.ch