mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-05-12 20:28:36 -07:00
Add option to disable fallback animation
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
#include <power/power_service/power.h>
|
||||
#include <storage/storage.h>
|
||||
#include <assets_icons.h>
|
||||
#include <assets_dolphin_internal.h>
|
||||
|
||||
#include "views/bubble_animation_view.h"
|
||||
#include "views/one_shot_animation_view.h"
|
||||
@@ -387,6 +388,12 @@ static StorageAnimation*
|
||||
furi_record_close(RECORD_DOLPHIN);
|
||||
uint32_t whole_weight = 0;
|
||||
|
||||
bool fallback = XTREME_SETTINGS()->fallback_anim;
|
||||
if(StorageAnimationList_size(animation_list) == dolphin_internal_size + 1 && !fallback) {
|
||||
// One ext anim and fallback disabled, dont skip current anim (current = only ext one)
|
||||
avoid_animation = NULL;
|
||||
}
|
||||
|
||||
StorageAnimationList_it_t it;
|
||||
bool unlock = XTREME_SETTINGS()->unlock_anims;
|
||||
for(StorageAnimationList_it(it, animation_list); !StorageAnimationList_end_p(it);) {
|
||||
@@ -399,6 +406,10 @@ static StorageAnimation*
|
||||
// Avoid repeating same animation twice
|
||||
valid = false;
|
||||
}
|
||||
if(strcmp(manifest_info->name, HARDCODED_ANIMATION_NAME) == 0 && !fallback) {
|
||||
// Skip fallback animation
|
||||
valid = false;
|
||||
}
|
||||
|
||||
if(valid) {
|
||||
whole_weight += manifest_info->weight;
|
||||
|
||||
@@ -39,6 +39,7 @@ void XTREME_SETTINGS_LOAD() {
|
||||
xtreme_settings->anim_speed = 100; // 100%
|
||||
xtreme_settings->cycle_anims = 0; // Meta.txt
|
||||
xtreme_settings->unlock_anims = false; // OFF
|
||||
xtreme_settings->fallback_anim = true; // ON
|
||||
xtreme_settings->wii_menu = true; // ON
|
||||
xtreme_settings->lockscreen_time = true; // ON
|
||||
xtreme_settings->lockscreen_date = true; // ON
|
||||
|
||||
@@ -15,7 +15,7 @@ extern "C" {
|
||||
|
||||
#define MAX_PACK_NAME_LEN 32
|
||||
|
||||
#define XTREME_SETTINGS_VERSION (9)
|
||||
#define XTREME_SETTINGS_VERSION (10)
|
||||
#define XTREME_SETTINGS_PATH_OLD INT_PATH(XTREME_SETTINGS_FILE_NAME)
|
||||
#define XTREME_SETTINGS_PATH EXT_PATH(XTREME_SETTINGS_FILE_NAME)
|
||||
#define XTREME_SETTINGS_MAGIC (0x69)
|
||||
@@ -27,6 +27,7 @@ typedef struct {
|
||||
uint16_t anim_speed;
|
||||
int32_t cycle_anims;
|
||||
bool unlock_anims;
|
||||
bool fallback_anim;
|
||||
bool wii_menu;
|
||||
bool lockscreen_time;
|
||||
bool lockscreen_date;
|
||||
|
||||
Reference in New Issue
Block a user