[FL-1477] Archive improvements (#541)

* various small issues fixes
* proper fadding to favourites
* cleanups
* fix infrared extension
* allow subdirs in app tabs
* fix elements_scrollbar args
* bugfixes, looping list, halfbaked pinning
* pinning
* ui updates

Co-authored-by: あく <alleteam@gmail.com>
This commit is contained in:
its your bedtime
2021-06-25 19:57:42 +03:00
committed by GitHub
parent c583cce5bd
commit 9d23602968
6 changed files with 201 additions and 82 deletions
+18 -3
View File
@@ -6,9 +6,8 @@
#include <furi.h>
#include <filesystem-api.h>
#define MAX_LEN_PX 98
#define MAX_LEN_PX 100
#define MAX_NAME_LEN 255
#define FRAME_HEIGHT 12
#define MENU_ITEMS 4
@@ -23,9 +22,21 @@ typedef enum {
AppIdTotal,
} ArchiveFileTypeEnum;
typedef enum {
ArchiveTabFavourites,
ArchiveTabLFRFID,
ArchiveTabSubOne,
ArchiveTabNFC,
ArchiveTabIButton,
ArchiveTabIrda,
ArchiveTabBrowser,
ArchiveTabTotal,
} ArchiveTabEnum;
typedef struct {
string_t name;
ArchiveFileTypeEnum type;
bool fav;
} ArchiveFile_t;
static void ArchiveFile_t_init(ArchiveFile_t* obj) {
@@ -65,4 +76,8 @@ typedef struct {
} ArchiveViewModel;
void archive_view_render(Canvas* canvas, void* model);
void archive_trim_file_ext(char* name);
void archive_trim_file_ext(char* name);
static inline bool is_known_app(ArchiveFileTypeEnum type) {
return (type != ArchiveFileTypeFolder && type != ArchiveFileTypeUnknown);
}