mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-05-14 10:58:36 -07:00
Format
This commit is contained in:
@@ -5,7 +5,8 @@
|
||||
#define SPI_MEM_DEVELOPER "DrunkBatya"
|
||||
#define SPI_MEM_GITHUB "https://github.com/flipperdevices/flipperzero-firmware"
|
||||
#define SPI_MEM_NAME "\e#\e! SPI Mem Manager \e!\n" // NOSONAR
|
||||
#define SPI_MEM_BLANK_INV "\e#\e! \e!\n" // NOSONAR
|
||||
#define SPI_MEM_BLANK_INV \
|
||||
"\e#\e! \e!\n" // NOSONAR
|
||||
|
||||
void spi_mem_scene_about_on_enter(void* context) {
|
||||
SPIMemApp* app = context;
|
||||
|
||||
@@ -338,7 +338,8 @@ static bool animation_storage_load_frames(
|
||||
frames_ok = false;
|
||||
furi_string_printf(filename, "%s/%s/frame_%d.bm", ANIMATION_DIR, name, i);
|
||||
do {
|
||||
if(storage_common_stat(storage, furi_string_get_cstr(filename), &file_info) != FSE_OK)
|
||||
if(storage_common_stat(storage, furi_string_get_cstr(filename), &file_info) !=
|
||||
FSE_OK)
|
||||
break;
|
||||
if(file_info.size > max_filesize) {
|
||||
FURI_LOG_E(
|
||||
@@ -351,13 +352,14 @@ static bool animation_storage_load_frames(
|
||||
break;
|
||||
}
|
||||
if(!storage_file_open(
|
||||
file, furi_string_get_cstr(filename), FSAM_READ, FSOM_OPEN_EXISTING)) {
|
||||
file, furi_string_get_cstr(filename), FSAM_READ, FSOM_OPEN_EXISTING)) {
|
||||
FURI_LOG_E(TAG, "Can't open file \'%s\'", furi_string_get_cstr(filename));
|
||||
break;
|
||||
}
|
||||
|
||||
FURI_CONST_ASSIGN_PTR(icon->frames[i], malloc(file_info.size));
|
||||
if(storage_file_read(file, (void*)icon->frames[i], file_info.size) != file_info.size) {
|
||||
if(storage_file_read(file, (void*)icon->frames[i], file_info.size) !=
|
||||
file_info.size) {
|
||||
FURI_LOG_E(TAG, "Read failed: \'%s\'", furi_string_get_cstr(filename));
|
||||
break;
|
||||
} else {
|
||||
|
||||
@@ -33,7 +33,8 @@ void anim(const Icon** replace, const char* name, FuriString* path, File* file)
|
||||
ok = false;
|
||||
furi_string_printf(path, ICONS_FMT "/frame_%02d.bm", pack, name, i);
|
||||
do {
|
||||
if(!storage_file_open(file, furi_string_get_cstr(path), FSAM_READ, FSOM_OPEN_EXISTING))
|
||||
if(!storage_file_open(
|
||||
file, furi_string_get_cstr(path), FSAM_READ, FSOM_OPEN_EXISTING))
|
||||
break;
|
||||
|
||||
uint64_t size = storage_file_size(file);
|
||||
|
||||
Reference in New Issue
Block a user