Compress things a bit

This commit is contained in:
zyphlar 2024-01-05 02:32:50 -08:00
parent d2989ae23a
commit 7cd9e8493d
Signed by: will
GPG Key ID: 1159B930701263F3
2 changed files with 3 additions and 11 deletions

View File

@ -94,7 +94,7 @@ void WatchFaceDigital::Refresh() {
/* Begin difference from WatchFaceDigital*/
if (settingsController.GetClockType() == Controllers::Settings::ClockType::Fuzzy) {
std::string hourStr, timeStr;
auto sector = minute / 5 + (minute % 5 > 2);
auto sector = minute / 15 + (minute % 15 > 7);
if (sector == 12) {
hour = (hour + 1) % 12;
sector = 0;
@ -183,18 +183,10 @@ void WatchFaceDigital::Refresh() {
*/
const char* WatchFaceDigital::timeSectors[] = {
"%0\no'clock",
"five past\n%0",
"ten past\n%0",
"quarter\npast\n%0",
"twenty\npast\n%0",
"twenty\nfive past\n%0",
"half past\n%0",
"twenty\nfive to\n%1",
"twenty\nto %1",
"quarter\nto %1",
"ten to\n%1",
"five to\n%1",
};
};
const char* WatchFaceDigital::hourNames[] = {
"twelve",
"one",

View File

@ -41,7 +41,7 @@ namespace Pinetime {
const char* timeAccent = "ffffff";
uint8_t displayedHour = -1;
uint8_t displayedMinute = -1;
static const char* timeSectors[12];
static const char* timeSectors[4];
static const char* hourNames[12];
Utility::DirtyValue<uint8_t> batteryPercentRemaining {};