diff --git a/CHANGELOG.md b/CHANGELOG.md index b51403f7c0..327e4446e7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,8 @@ * OFW: iButton ID writing (Enable ID writing for ds1971 and ds1996) * Apps: **Check out more Apps updates and fixes by following** [this link](https://github.com/xMasterX/all-the-plugins/commits/dev) ## Other changes +* Archive: Fix BadUSB favourite path check +* Settings: Show free flash amount in internal storage info (by @Willy-JL) * Misc: Fix typo in comment in QueueTools.py (by @eltociear | PR #785) * OFW PR 3840: GUI: NumberInput small improvements (by @Willy-JL) * OFW PR 3838: SubGhz: Fix RPC status for ButtonRelease event (by @Skorpionm) diff --git a/applications/main/archive/helpers/archive_files.c b/applications/main/archive/helpers/archive_files.c index 868fa8a117..f4b49cd0e8 100644 --- a/applications/main/archive/helpers/archive_files.c +++ b/applications/main/archive/helpers/archive_files.c @@ -17,8 +17,8 @@ void archive_set_file_type(ArchiveFile_t* file, const char* path, bool is_folder if((known_ext[i][0] == '?') || (known_ext[i][0] == '*')) continue; if(furi_string_end_withi(file->path, known_ext[i])) { if((i == ArchiveFileTypeBadUsb) || (i == ArchiveFileTypeSubGhzRemote)) { - if(furi_string_search( - file->path, archive_get_default_path(ArchiveTabBadUsb)) == 0) { + if((furi_string_search(file->path, EXT_PATH("badusb")) == 0) || + (furi_string_search(file->path, ANY_PATH("badusb")) == 0)) { file->type = ArchiveFileTypeBadUsb; return; // *.txt file is a BadUSB script only if it is in BadUSB folder } diff --git a/applications/settings/storage_settings/scenes/storage_settings_scene_internal_info.c b/applications/settings/storage_settings/scenes/storage_settings_scene_internal_info.c index 5a367afcec..87a7ac6550 100644 --- a/applications/settings/storage_settings/scenes/storage_settings_scene_internal_info.c +++ b/applications/settings/storage_settings/scenes/storage_settings_scene_internal_info.c @@ -1,5 +1,6 @@ #include "../storage_settings.h" #include +#include static void storage_settings_scene_internal_info_dialog_callback(DialogExResult result, void* context) { @@ -27,10 +28,20 @@ void storage_settings_scene_internal_info_on_enter(void* context) { } else { furi_string_printf( app->text_string, - "Name: %s\nType: Virtual\nTotal: %lu KiB\nFree: %lu KiB", + "Name: %s\nType: Virtual (/.int on SD)\nTotal: %lu KiB\nFree: %lu KiB\n", furi_hal_version_get_name_ptr() ? furi_hal_version_get_name_ptr() : "Unknown", (uint32_t)(total_space / 1024), (uint32_t)(free_space / 1024)); + + uint32_t free_flash = + furi_hal_flash_get_free_end_address() - furi_hal_flash_get_free_start_address(); + if(free_flash < 1024) { + furi_string_cat_printf(app->text_string, "Flash: %lu B free", free_flash); + } else { + furi_string_cat_printf( + app->text_string, "Flash: %.2f KiB free", (double)free_flash / 1024); + } + dialog_ex_set_text( dialog_ex, furi_string_get_cstr(app->text_string), 4, 4, AlignLeft, AlignTop); }