Removed battery percent from digital watch face
This commit is contained in:
parent
13af2bb96c
commit
94044d2fdc
@ -22,7 +22,6 @@ WatchFaceDigital::WatchFaceDigital(Controllers::DateTime& dateTimeController,
|
|||||||
Controllers::MotionController& motionController)
|
Controllers::MotionController& motionController)
|
||||||
: currentDateTime {{}},
|
: currentDateTime {{}},
|
||||||
dateTimeController {dateTimeController},
|
dateTimeController {dateTimeController},
|
||||||
batteryController {batteryController},
|
|
||||||
notificationManager {notificationManager},
|
notificationManager {notificationManager},
|
||||||
settingsController {settingsController},
|
settingsController {settingsController},
|
||||||
heartRateController {heartRateController},
|
heartRateController {heartRateController},
|
||||||
@ -36,11 +35,6 @@ WatchFaceDigital::WatchFaceDigital(Controllers::DateTime& dateTimeController,
|
|||||||
lv_label_set_text_static(notificationIcon, NotificationIcon::GetIcon(false));
|
lv_label_set_text_static(notificationIcon, NotificationIcon::GetIcon(false));
|
||||||
lv_obj_align(notificationIcon, nullptr, LV_ALIGN_IN_TOP_LEFT, 0, 0);
|
lv_obj_align(notificationIcon, nullptr, LV_ALIGN_IN_TOP_LEFT, 0, 0);
|
||||||
|
|
||||||
|
|
||||||
batteryValue = lv_label_create(lv_scr_act(), nullptr);
|
|
||||||
//lv_label_set_recolor(batteryValue, true);
|
|
||||||
lv_obj_align(batteryValue, lv_scr_act(), LV_ALIGN_IN_RIGHT_MID, -3, -110);
|
|
||||||
|
|
||||||
label_seconds = lv_label_create(lv_scr_act(), nullptr); // for secs
|
label_seconds = lv_label_create(lv_scr_act(), nullptr); // for secs
|
||||||
lv_obj_align(label_seconds, lv_scr_act(), LV_ALIGN_IN_RIGHT_MID, 0, -55);
|
lv_obj_align(label_seconds, lv_scr_act(), LV_ALIGN_IN_RIGHT_MID, 0, -55);
|
||||||
lv_obj_set_style_local_text_color(label_seconds, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, lv_color_hex(0x999999));
|
lv_obj_set_style_local_text_color(label_seconds, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, lv_color_hex(0x999999));
|
||||||
@ -89,11 +83,6 @@ WatchFaceDigital::~WatchFaceDigital() {
|
|||||||
|
|
||||||
void WatchFaceDigital::Refresh() {
|
void WatchFaceDigital::Refresh() {
|
||||||
statusIcons.Update();
|
statusIcons.Update();
|
||||||
|
|
||||||
batteryPercentRemaining = batteryController.PercentRemaining();
|
|
||||||
if (batteryPercentRemaining.IsUpdated()) {
|
|
||||||
lv_label_set_text_fmt(batteryValue, "%d%%", batteryPercentRemaining.Get());
|
|
||||||
}
|
|
||||||
|
|
||||||
notificationState = notificationManager.AreNewNotificationsAvailable();
|
notificationState = notificationManager.AreNewNotificationsAvailable();
|
||||||
if (notificationState.IsUpdated()) {
|
if (notificationState.IsUpdated()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user