I am using the following code to make my game exit when the back button is pressed...
stage:addEventListener(Event.KEY_DOWN, function(event)
if event.keyCode == KeyCode.BACK then
application:exit()
end
end) |
This seems to work but when you press the button that shows all running apps.. the game is sitting there in that list and has not exited correctly. If I click it in the list of running apps it then starts the app again.
Is this a bug and is it possibly resolved later than 2016.6 which I'm currently using?
Comments
\
https://deluxepixel.com
However, android may choose to retain the activity in memory but frozen, just in case the user wants to start it again right after.
http://stackoverflow.com/questions/10847526/what-exactly-activity-finish-method-is-doing
Likes: SinisterSoft
https://deluxepixel.com
Anyway, it would be good if when I asked the application to exit, that it actually disappeared totally
http://blog.radioactiveyak.com/2010/05/when-to-include-exit-button-in-android.html
http://stackoverflow.com/questions/16967356/why-my-app-still-visible-in-task-manager-after-finishing-it
Likes: antix