diff options
| author | Jean-François Milants <jf@codingfield.com> | 2022-09-11 14:59:49 +0200 |
|---|---|---|
| committer | Jean-François Milants <jf@codingfield.com> | 2022-09-11 14:59:49 +0200 |
| commit | ada2c09581d2d13acfa5ce9a97671c0ec17863f1 (patch) | |
| tree | 2f776adc59d0c63e403d2043cb8460e65d6c46fe /src/displayapp/screens/SystemInfo.cpp | |
| parent | 18cff286c75f432095db4b188e0f9a8a9e2bd8e8 (diff) | |
| parent | c9a5c3fa5c930a5939d3114a6c6b48570d61ca24 (diff) | |
Merge branch 'develop' into infineat-external-resources
# Conflicts:
# src/displayapp/screens/Symbols.h
# src/displayapp/screens/settings/SettingWatchFace.cpp
# src/displayapp/screens/settings/SettingWatchFace.h
Diffstat (limited to 'src/displayapp/screens/SystemInfo.cpp')
| -rw-r--r-- | src/displayapp/screens/SystemInfo.cpp | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/src/displayapp/screens/SystemInfo.cpp b/src/displayapp/screens/SystemInfo.cpp index e3983d7c..01c35195 100644 --- a/src/displayapp/screens/SystemInfo.cpp +++ b/src/displayapp/screens/SystemInfo.cpp @@ -12,6 +12,7 @@ #include "components/datetime/DateTimeController.h" #include "components/motion/MotionController.h" #include "drivers/Watchdog.h" +#include "displayapp/InfiniTimeTheme.h" using namespace Pinetime::Applications::Screens; @@ -136,20 +137,25 @@ std::unique_ptr<Screen> SystemInfo::CreateScreen2() { uptimeSeconds = uptimeSeconds % secondsInAMinute; // TODO handle more than 100 days of uptime +#ifndef TARGET_DEVICE_NAME + #define TARGET_DEVICE_NAME "UNKNOWN" +#endif + lv_obj_t* label = lv_label_create(lv_scr_act(), nullptr); lv_label_set_recolor(label, true); lv_label_set_text_fmt(label, - "#808080 Date# %02d/%02d/%04d\n" + "#808080 Date# %04d-%02d-%02d\n" "#808080 Time# %02d:%02d:%02d\n" "#808080 Uptime#\n %02lud %02lu:%02lu:%02lu\n" "#808080 Battery# %d%%/%03imV\n" "#808080 Backlight# %s\n" "#808080 Last reset# %s\n" "#808080 Accel.# %s\n" - "#808080 Touch.# %x.%x.%x\n", - dateTimeController.Day(), - static_cast<uint8_t>(dateTimeController.Month()), + "#808080 Touch.# %x.%x.%x\n" + "#808080 Model# %s", dateTimeController.Year(), + static_cast<uint8_t>(dateTimeController.Month()), + dateTimeController.Day(), dateTimeController.Hours(), dateTimeController.Minutes(), dateTimeController.Seconds(), @@ -164,7 +170,8 @@ std::unique_ptr<Screen> SystemInfo::CreateScreen2() { ToString(motionController.DeviceType()), touchPanel.GetChipId(), touchPanel.GetVendorId(), - touchPanel.GetFwVersion()); + touchPanel.GetFwVersion(), + TARGET_DEVICE_NAME); lv_obj_align(label, lv_scr_act(), LV_ALIGN_CENTER, 0, 0); return std::make_unique<Screens::Label>(1, 5, app, label); } @@ -212,7 +219,7 @@ std::unique_ptr<Screen> SystemInfo::CreateScreen4() { lv_table_set_col_cnt(infoTask, 4); lv_table_set_row_cnt(infoTask, maxTaskCount + 1); lv_obj_set_style_local_pad_all(infoTask, LV_TABLE_PART_CELL1, LV_STATE_DEFAULT, 0); - lv_obj_set_style_local_border_color(infoTask, LV_TABLE_PART_CELL1, LV_STATE_DEFAULT, LV_COLOR_MAKE(0xb0, 0xb0, 0xb0)); + lv_obj_set_style_local_border_color(infoTask, LV_TABLE_PART_CELL1, LV_STATE_DEFAULT, Colors::lightGray); lv_table_set_cell_value(infoTask, 0, 0, "#"); lv_table_set_col_width(infoTask, 0, 30); |
