mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-04-24 03:29:57 -07:00
Add header to xtreme app, move intro button
This commit is contained in:
@@ -5,6 +5,7 @@ enum VarItemListIndex {
|
||||
VarItemListIndexDolphin,
|
||||
VarItemListIndexChangeDeviceName,
|
||||
VarItemListIndexChargeCap,
|
||||
VarItemListIndexShowXtremeIntro,
|
||||
};
|
||||
|
||||
void xtreme_app_scene_misc_var_item_list_callback(void* context, uint32_t index) {
|
||||
@@ -50,6 +51,8 @@ void xtreme_app_scene_misc_on_enter(void* context) {
|
||||
variable_item_set_current_value_index(item, value_index - 1);
|
||||
variable_item_set_current_value_text(item, cap_str);
|
||||
|
||||
variable_item_list_add(var_item_list, "Show Xtreme Intro", 0, NULL, app);
|
||||
|
||||
variable_item_list_set_enter_callback(
|
||||
var_item_list, xtreme_app_scene_misc_var_item_list_callback, app);
|
||||
|
||||
@@ -79,6 +82,19 @@ bool xtreme_app_scene_misc_on_event(void* context, SceneManagerEvent event) {
|
||||
scene_manager_set_scene_state(app->scene_manager, XtremeAppSceneMiscRename, 0);
|
||||
scene_manager_next_scene(app->scene_manager, XtremeAppSceneMiscRename);
|
||||
break;
|
||||
case VarItemListIndexShowXtremeIntro: {
|
||||
for(int i = 0; i < 10; i++) {
|
||||
if(storage_common_copy(
|
||||
furi_record_open(RECORD_STORAGE),
|
||||
EXT_PATH("dolphin/xfwfirstboot.bin"),
|
||||
EXT_PATH(".slideshow"))) {
|
||||
app->show_slideshow = true;
|
||||
xtreme_app_apply(app);
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -4,7 +4,6 @@ enum VarItemListIndex {
|
||||
VarItemListIndexInterface,
|
||||
VarItemListIndexProtocols,
|
||||
VarItemListIndexMisc,
|
||||
VarItemListIndexVersion,
|
||||
};
|
||||
|
||||
void xtreme_app_scene_start_var_item_list_callback(void* context, uint32_t index) {
|
||||
@@ -26,7 +25,7 @@ void xtreme_app_scene_start_on_enter(void* context) {
|
||||
item = variable_item_list_add(var_item_list, "Misc", 0, NULL, app);
|
||||
variable_item_set_current_value_text(item, ">");
|
||||
|
||||
variable_item_list_add(var_item_list, furi_string_get_cstr(app->version_tag), 0, NULL, app);
|
||||
variable_item_list_set_header(var_item_list, furi_string_get_cstr(app->version_tag));
|
||||
|
||||
variable_item_list_set_enter_callback(
|
||||
var_item_list, xtreme_app_scene_start_var_item_list_callback, app);
|
||||
@@ -57,19 +56,6 @@ bool xtreme_app_scene_start_on_event(void* context, SceneManagerEvent event) {
|
||||
scene_manager_set_scene_state(app->scene_manager, XtremeAppSceneMisc, 0);
|
||||
scene_manager_next_scene(app->scene_manager, XtremeAppSceneMisc);
|
||||
break;
|
||||
case VarItemListIndexVersion: {
|
||||
for(int i = 0; i < 10; i++) {
|
||||
if(storage_common_copy(
|
||||
furi_record_open(RECORD_STORAGE),
|
||||
EXT_PATH("dolphin/xfwfirstboot.bin"),
|
||||
EXT_PATH(".slideshow"))) {
|
||||
app->show_slideshow = true;
|
||||
xtreme_app_apply(app);
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user