PDA

View Full Version : how to close the native app in in sencha touch on ipad



15 May 2013, 11:28 PM
i am working on a native app in sencha touch. I hope i can click a button to quit and close the app like normal native app .
How can I do it ?
thanks in advance

tobiu
16 May 2013, 8:33 AM
As far as I know Apple does not allow apps to programmatically exit.

16 May 2013, 6:02 PM
Hi, tobiu . Thanks your reply . but this is a misunderstanding between us . In fact , I don't want to kill my app , I just want to my app disappear after user click the "cancel " button in the login page . I want the effect is same as users click the "home " key on the ipad .
Any idea ?
thanks again

tobiu
17 May 2013, 9:38 AM
still i don't think it is possible.

take a look at:
https://developer.apple.com/library/ios/#qa/qa2008/qa1561.html

there is also a quite long discussion on SO:
http://stackoverflow.com/questions/355168/proper-way-to-exit-iphone-application

so if you wrap your st app using phonegap / cordova, you can use exit(), at least for debugging. if your app will get approved to get into the store is a different story if you keep it.

garciacamilla
8 Jan 2016, 12:54 AM
That closes it entirely from the device. If its coming back for some reason, then there's something else you are doing or not doing. If the App was synced to a computer running iTunes and then removed from the iPad, a future sync will put it back onto the iPad. You would need to delete it from iTunes on the computer as well. Hope it can help you to close the native app in in sencha touch on ipad.