mirror of
https://github.com/Next-Flip/Momentum-Firmware.git
synced 2026-04-24 03:29:57 -07:00
* feat(Archive): Adds dynamic paths to browser tab I thought it would be cool to be able to see when I was in say the `apps_data/flipchess` folder, or some other nested folder, and have "flipchess" be shown rather than the just "Browser" all the time. It's not a huge or really crucial change, just a personal modification that some people may also find useful. * fix(Archive): Clean up, built-ins, safer Cleaned up `archive_update_formatted_path` function using switch case, and also using the built in furi functions where possible. Also removed the arbitrary and unnecessary `path_buf[256]`, making formatting the path in the Brief section more memory safe. * Rename setting and use setting_enum() * Remove prev_path * Enum names * Single text draw call * Rename to statusbar title * Revert "Rename to statusbar title" This reverts commit243f2a754f. * Revert "Single text draw call" This reverts commit3bbe30449b. * Simpler fix * Shorter setting label * Update changelog --------- Co-authored-by: Willy-JL <49810075+Willy-JL@users.noreply.github.com>
108 lines
2.4 KiB
C
108 lines
2.4 KiB
C
#pragma once
|
|
|
|
#include <furi_hal_serial_types.h>
|
|
#include <furi_hal_version.h>
|
|
#include <stdint.h>
|
|
#include <toolbox/colors.h>
|
|
|
|
#define MOMENTUM_SETTINGS_PATH INT_PATH(".momentum_settings.txt")
|
|
|
|
#define ASSET_PACKS_NAME_LEN 32
|
|
|
|
typedef enum {
|
|
BatteryIconOff,
|
|
BatteryIconBar,
|
|
BatteryIconPercent,
|
|
BatteryIconInvertedPercent,
|
|
BatteryIconRetro3,
|
|
BatteryIconRetro5,
|
|
BatteryIconBarPercent,
|
|
BatteryIconCount,
|
|
} BatteryIcon;
|
|
|
|
typedef enum {
|
|
MenuStyleList,
|
|
MenuStyleWii,
|
|
MenuStyleDsi,
|
|
MenuStylePs4,
|
|
MenuStyleVertical,
|
|
MenuStyleC64,
|
|
MenuStyleCompact,
|
|
MenuStyleMNTM,
|
|
MenuStyleCoverFlow,
|
|
MenuStyleCount,
|
|
} MenuStyle;
|
|
|
|
typedef enum {
|
|
SpiDefault, // CS on pa4
|
|
SpiExtra, // CS on pc3
|
|
SpiCount,
|
|
} SpiHandle;
|
|
|
|
typedef enum {
|
|
ScreenColorModeDefault,
|
|
ScreenColorModeCustom,
|
|
ScreenColorModeRainbow,
|
|
ScreenColorModeRgbBacklight,
|
|
ScreenColorModeCount,
|
|
} ScreenColorMode;
|
|
|
|
typedef union __attribute__((packed)) {
|
|
struct {
|
|
ScreenColorMode mode;
|
|
RgbColor rgb;
|
|
};
|
|
uint32_t value;
|
|
} ScreenFrameColor;
|
|
|
|
typedef enum {
|
|
BrowserPathOff,
|
|
BrowserPathCurrent,
|
|
BrowserPathBrief,
|
|
BrowserPathFull,
|
|
BrowserPathModeCount,
|
|
} BrowserPathMode;
|
|
|
|
typedef struct {
|
|
char asset_pack[ASSET_PACKS_NAME_LEN];
|
|
uint32_t anim_speed;
|
|
int32_t cycle_anims;
|
|
bool unlock_anims;
|
|
MenuStyle menu_style;
|
|
bool lock_on_boot;
|
|
bool bad_pins_format;
|
|
bool allow_locked_rpc_usb;
|
|
bool allow_locked_rpc_ble;
|
|
bool lockscreen_poweroff;
|
|
bool lockscreen_time;
|
|
bool lockscreen_seconds;
|
|
bool lockscreen_date;
|
|
bool lockscreen_statusbar;
|
|
bool lockscreen_prompt;
|
|
bool lockscreen_transparent;
|
|
BatteryIcon battery_icon;
|
|
bool status_icons;
|
|
bool bar_borders;
|
|
bool bar_background;
|
|
bool sort_dirs_first;
|
|
bool show_hidden_files;
|
|
bool show_internal_tab;
|
|
BrowserPathMode browser_path_mode;
|
|
uint32_t favorite_timeout;
|
|
bool dark_mode;
|
|
bool rgb_backlight;
|
|
uint32_t butthurt_timer;
|
|
uint32_t charge_cap;
|
|
SpiHandle spi_cc1101_handle;
|
|
SpiHandle spi_nrf24_handle;
|
|
FuriHalSerialId uart_esp_channel;
|
|
FuriHalSerialId uart_nmea_channel;
|
|
bool file_naming_prefix_after;
|
|
FuriHalVersionColor spoof_color;
|
|
ScreenFrameColor rpc_color_fg;
|
|
ScreenFrameColor rpc_color_bg;
|
|
} MomentumSettings;
|
|
|
|
void momentum_settings_save(void);
|
|
extern MomentumSettings momentum_settings;
|