unleashed-firmware/applications/ibutton/scene/ibutton-scene-select-key.cpp
SG 7e6a97c3a3
[FL-1307] iButton key files: ASCII encoding and .ibtn extension (#493)
* GUI module submenu: fix documentation
* GUI module submenu: add submenu_set_selected_item fn
* App iButton: use submenu_set_selected_item to store and set selected item in submenu
* App iButton: swap write and emulate in "saved key menu" scene
* App iButton: file select can now switch to the previous selected file
* App iButton: swap write and emulate indexes in "saved key menu" scene
* Gui module file_select: work with separate extension
* iButton app: separate file managment, file error handling
* SD card api: custom error message
* iButton app: better file error handling

Co-authored-by: あく <alleteam@gmail.com>
2021-05-26 19:50:16 +03:00

21 lines
532 B
C++

#include "ibutton-scene-select-key.h"
#include "../ibutton-app.h"
#include "../ibutton-event.h"
#include "../ibutton-key.h"
void iButtonSceneSelectKey::on_enter(iButtonApp* app) {
// Process file_select return
if(app->load_key()) {
app->switch_to_next_scene(iButtonApp::Scene::SceneSavedKeyMenu);
} else {
app->switch_to_previous_scene();
}
}
bool iButtonSceneSelectKey::on_event(iButtonApp* app, iButtonEvent* event) {
return false;
}
void iButtonSceneSelectKey::on_exit(iButtonApp* app) {
}