feat: add top panel widgets
This commit is contained in:
1 parent
352c1307fe
commit
b8085e0e2a
14 files changed
+1016
-47
No files matched your search
@@ -17,7 +17,7 @@ namespace settings_app {
|
||||
|
||||
struct SettingsState {
|
||||
DesktopState* desktop;
|
||||
int active_tab; // 0=Appearance, 1=Display, 2=About
|
||||
int active_tab; // 0=Appearance, 1=Display, 2=Widgets, 3=About
|
||||
montauk::abi::SysInfo sys_info;
|
||||
uint64_t uptime_ms;
|
||||
WallpaperFileList wp_files;
|
||||
@@ -68,8 +68,8 @@ inline const Color accent_palette[SWATCH_COUNT] = {
|
||||
};
|
||||
|
||||
inline constexpr int TAB_BAR_H = 36;
|
||||
inline constexpr int TAB_COUNT = 3;
|
||||
inline constexpr const char* tab_labels[TAB_COUNT] = { "Appearance", "Display", "About" };
|
||||
inline constexpr int TAB_COUNT = 4;
|
||||
inline constexpr const char* tab_labels[TAB_COUNT] = { "Appearance", "Display", "Widgets", "About" };
|
||||
|
||||
inline constexpr int WP_ITEM_H = 24;
|
||||
|
||||
@@ -90,6 +90,9 @@ bool settings_handle_appearance_click(Window* win, SettingsState* st, int mx, in
|
||||
void settings_draw_display(Canvas& c, SettingsState* st);
|
||||
bool settings_handle_display_click(SettingsState* st, int mx, int cy);
|
||||
|
||||
void settings_draw_widgets(Canvas& c, SettingsState* st);
|
||||
bool settings_handle_widgets_click(Window* win, SettingsState* st, int mx, int cy);
|
||||
|
||||
void settings_draw_about(Canvas& c, SettingsState* st);
|
||||
|
||||
void settings_persist(SettingsState* st);
|
||||
|
||||
Reference in new issue
Block a user