mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-05-15 04:19:26 -07:00
Archive: Favorite .mag files (#110)
* Impl mag file favoriting, add icon * Revert API ver * No weird formatting --------- Co-authored-by: Willy-JL <49810075+Willy-JL@users.noreply.github.com>
This commit is contained in:
@@ -24,6 +24,7 @@ static const char* tab_default_paths[] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
static const char* known_ext[] = {
|
static const char* known_ext[] = {
|
||||||
|
// clang-format off
|
||||||
[ArchiveFileTypeIButton] = ".ibtn",
|
[ArchiveFileTypeIButton] = ".ibtn",
|
||||||
[ArchiveFileTypeNFC] = ".nfc",
|
[ArchiveFileTypeNFC] = ".nfc",
|
||||||
[ArchiveFileTypeSubGhz] = ".sub",
|
[ArchiveFileTypeSubGhz] = ".sub",
|
||||||
@@ -34,6 +35,7 @@ static const char* known_ext[] = {
|
|||||||
[ArchiveFileTypeInfraredRemote] = ".txt",
|
[ArchiveFileTypeInfraredRemote] = ".txt",
|
||||||
[ArchiveFileTypeBadKb] = ".txt",
|
[ArchiveFileTypeBadKb] = ".txt",
|
||||||
[ArchiveFileTypeWAV] = ".wav",
|
[ArchiveFileTypeWAV] = ".wav",
|
||||||
|
[ArchiveFileTypeMag] = ".mag",
|
||||||
[ArchiveFileTypeU2f] = "?",
|
[ArchiveFileTypeU2f] = "?",
|
||||||
[ArchiveFileTypeApplication] = ".fap",
|
[ArchiveFileTypeApplication] = ".fap",
|
||||||
[ArchiveFileTypeJS] = ".js",
|
[ArchiveFileTypeJS] = ".js",
|
||||||
@@ -43,6 +45,7 @@ static const char* known_ext[] = {
|
|||||||
[ArchiveFileTypeFolder] = "?",
|
[ArchiveFileTypeFolder] = "?",
|
||||||
[ArchiveFileTypeUnknown] = "*",
|
[ArchiveFileTypeUnknown] = "*",
|
||||||
[ArchiveFileTypeAppOrJs] = ".fap|.js",
|
[ArchiveFileTypeAppOrJs] = ".fap|.js",
|
||||||
|
// clang-format on
|
||||||
};
|
};
|
||||||
|
|
||||||
static const ArchiveFileTypeEnum known_type[] = {
|
static const ArchiveFileTypeEnum known_type[] = {
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ typedef enum {
|
|||||||
ArchiveFileTypeInfraredRemote,
|
ArchiveFileTypeInfraredRemote,
|
||||||
ArchiveFileTypeBadKb,
|
ArchiveFileTypeBadKb,
|
||||||
ArchiveFileTypeWAV,
|
ArchiveFileTypeWAV,
|
||||||
|
ArchiveFileTypeMag,
|
||||||
ArchiveFileTypeU2f,
|
ArchiveFileTypeU2f,
|
||||||
ArchiveFileTypeApplication,
|
ArchiveFileTypeApplication,
|
||||||
ArchiveFileTypeJS,
|
ArchiveFileTypeJS,
|
||||||
|
|||||||
@@ -34,6 +34,8 @@ const char* archive_get_flipper_app_name(ArchiveFileTypeEnum file_type) {
|
|||||||
return "Bad KB";
|
return "Bad KB";
|
||||||
case ArchiveFileTypeWAV:
|
case ArchiveFileTypeWAV:
|
||||||
return EXT_PATH("apps/Media/wav_player.fap");
|
return EXT_PATH("apps/Media/wav_player.fap");
|
||||||
|
case ArchiveFileTypeMag:
|
||||||
|
return EXT_PATH("apps/GPIO/magspoof.fap");
|
||||||
case ArchiveFileTypeU2f:
|
case ArchiveFileTypeU2f:
|
||||||
return "U2F";
|
return "U2F";
|
||||||
case ArchiveFileTypeUpdateManifest:
|
case ArchiveFileTypeUpdateManifest:
|
||||||
|
|||||||
@@ -35,6 +35,7 @@ static const Icon* ArchiveItemIcons[] = {
|
|||||||
[ArchiveFileTypeInfraredRemote] = &I_ir_scope_10px,
|
[ArchiveFileTypeInfraredRemote] = &I_ir_scope_10px,
|
||||||
[ArchiveFileTypeBadKb] = &I_badkb_10px,
|
[ArchiveFileTypeBadKb] = &I_badkb_10px,
|
||||||
[ArchiveFileTypeWAV] = &I_music_10px,
|
[ArchiveFileTypeWAV] = &I_music_10px,
|
||||||
|
[ArchiveFileTypeMag] = &I_mag_card_10px,
|
||||||
[ArchiveFileTypeU2f] = &I_u2f_10px,
|
[ArchiveFileTypeU2f] = &I_u2f_10px,
|
||||||
[ArchiveFileTypeApplication] = &I_Apps_10px,
|
[ArchiveFileTypeApplication] = &I_Apps_10px,
|
||||||
[ArchiveFileTypeJS] = &I_js_script_10px,
|
[ArchiveFileTypeJS] = &I_js_script_10px,
|
||||||
|
|||||||
BIN
assets/icons/Archive/mag_card_10px.png
Normal file
BIN
assets/icons/Archive/mag_card_10px.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.3 KiB |
@@ -3940,6 +3940,7 @@ Variable,+,I_ir_scope_10px,Icon,
|
|||||||
Variable,+,I_js_script_10px,Icon,
|
Variable,+,I_js_script_10px,Icon,
|
||||||
Variable,+,I_keyboard_10px,Icon,
|
Variable,+,I_keyboard_10px,Icon,
|
||||||
Variable,+,I_loading_10px,Icon,
|
Variable,+,I_loading_10px,Icon,
|
||||||
|
Variable,+,I_mag_card_10px,Icon,
|
||||||
Variable,+,I_max_24x23,Icon,
|
Variable,+,I_max_24x23,Icon,
|
||||||
Variable,+,I_max_hover_24x23,Icon,
|
Variable,+,I_max_hover_24x23,Icon,
|
||||||
Variable,+,I_menu_text_20x5,Icon,
|
Variable,+,I_menu_text_20x5,Icon,
|
||||||
|
|||||||
|
Reference in New Issue
Block a user