Hello,
I try to run android example through wiki "Tutorial: Building SFML for Android".
As was expected it worked.
I added Escape key release checking to close via Back button on the tablet.
if (event.type == sf::Event::KeyReleased)
{
if (event.key.code == sf::Keyboard::Escape)
window.close();
}
It can not close properly.
Any idea ? What can I do ?
Thanks
Edit:
I noticed same question at this link :(
http://en.sfml-dev.org/forums/index.php?PHPSESSID=ot7h2v1oj9hmn1qop9q78i4s03&topic=19145.msg141108#msg141108
Make sure to leave your main() after you've closed the window. Any chance you forgot doing that?
I hope it gives you an idea to find close problem.
as I can see std::exit(0);
can close completely.
1. I tried to control via isClosed boolean var. does not work
if (event.key.code == sf::Keyboard::Escape)
{
isClose = true;
window.close();
}
2. I tried to return 0 does not work
window.close();
return 0;