mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-05-16 04:24:45 -07:00
Small xfw app renames
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
#include "../xtreme_app.h"
|
||||
|
||||
enum TextInputIndex {
|
||||
TextInputIndexResult,
|
||||
TextInputResultOk,
|
||||
};
|
||||
|
||||
static void xtreme_app_scene_misc_rename_text_input_callback(void* context) {
|
||||
@@ -9,7 +9,7 @@ static void xtreme_app_scene_misc_rename_text_input_callback(void* context) {
|
||||
|
||||
app->save_name = true;
|
||||
app->require_reboot = true;
|
||||
view_dispatcher_send_custom_event(app->view_dispatcher, TextInputIndexResult);
|
||||
view_dispatcher_send_custom_event(app->view_dispatcher, TextInputResultOk);
|
||||
}
|
||||
|
||||
void xtreme_app_scene_misc_rename_on_enter(void* context) {
|
||||
@@ -36,7 +36,7 @@ bool xtreme_app_scene_misc_rename_on_event(void* context, SceneManagerEvent even
|
||||
if(event.type == SceneManagerEventTypeCustom) {
|
||||
consumed = true;
|
||||
switch(event.event) {
|
||||
case TextInputIndexResult:
|
||||
case TextInputResultOk:
|
||||
scene_manager_previous_scene(app->scene_manager);
|
||||
break;
|
||||
default:
|
||||
|
||||
@@ -6,7 +6,7 @@ static bool xtreme_app_custom_event_callback(void* context, uint32_t event) {
|
||||
return scene_manager_handle_custom_event(app->scene_manager, event);
|
||||
}
|
||||
|
||||
void xtreme_app_reboot(void* context) {
|
||||
void callback_reboot(void* context) {
|
||||
UNUSED(context);
|
||||
power_reboot(PowerBootModeNormal);
|
||||
}
|
||||
@@ -96,7 +96,7 @@ static bool xtreme_app_back_event_callback(void* context) {
|
||||
if(app->require_reboot) {
|
||||
popup_set_header(app->popup, "Rebooting...", 64, 26, AlignCenter, AlignCenter);
|
||||
popup_set_text(app->popup, "Applying changes...", 64, 40, AlignCenter, AlignCenter);
|
||||
popup_set_callback(app->popup, xtreme_app_reboot);
|
||||
popup_set_callback(app->popup, callback_reboot);
|
||||
popup_set_context(app->popup, app);
|
||||
popup_set_timeout(app->popup, 1000);
|
||||
popup_enable_timeout(app->popup);
|
||||
|
||||
Reference in New Issue
Block a user