aseba-community / thymio-vpl2

Next generation VPL for Thymio using Qt Quick from Qt 5.x
GNU Lesser General Public License v3.0
2 stars 5 forks source link

Program autosave #56

Closed stephanemagnenat closed 7 years ago

stephanemagnenat commented 7 years ago

Every time run is pressed, the program should be saved in the database in an "autosave" entry. When started, the autosave program should be loaded.

Indeed, if the user switches apps, the app might be stopped and the program lost.

According to https://wiki.qt.io/Qt_for_Android_known_issues:

By default the Back key will terminate Qt for Android apps, unless the key event is accepted. Unfortunately, due to misleading documentation (QTBUG-35155), many applications (including Qt examples) are incorrect, and will block the back key. We recommend making the logic explicit: always accept() the Key_Back event, and quit() the application explicitly if required.

... while problem might be due to not accepting the back key, but anyway an autosave would be a nice feature, and the app might be stopped by the operating system for low-memory reasons anyway.

stephanemagnenat commented 7 years ago

Implemented in 6a82e17.