diff options
| author | Avamander <avamander@gmail.com> | 2021-06-24 22:07:40 (GMT) |
|---|---|---|
| committer | JF002 <JF002@users.noreply.github.com> | 2021-07-02 14:27:16 (GMT) |
| commit | 2f479e5fc7688ae47e99c0f4aead87c9cdc29123 (patch) | |
| tree | 32999edc5cf9b00f9e22b786cb462cec6ef94520 /src/displayapp/screens/Timer.cpp | |
| parent | f317d54218659af437d840d00fd349e7919a243f (diff) | |
Fixed a bunch of format specifiers
Diffstat (limited to 'src/displayapp/screens/Timer.cpp')
| -rw-r--r-- | src/displayapp/screens/Timer.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/displayapp/screens/Timer.cpp b/src/displayapp/screens/Timer.cpp index 260a17e..99e979b 100644 --- a/src/displayapp/screens/Timer.cpp +++ b/src/displayapp/screens/Timer.cpp @@ -63,8 +63,8 @@ Timer::Timer(DisplayApp* app, Controllers::TimerController& timerController) lv_obj_set_style_local_text_color(time, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, LV_COLOR_GRAY); uint32_t seconds = timerController.GetTimeRemaining() / 1000; - lv_label_set_text_fmt(time, "%02d:%02d", seconds / 60, seconds % 60); - + lv_label_set_text_fmt(time, "%02lu:%02lu", seconds / 60, seconds % 60); + lv_obj_align(time, lv_scr_act(), LV_ALIGN_IN_LEFT_MID, 0, -20); btnPlayPause = lv_btn_create(lv_scr_act(), nullptr); @@ -90,7 +90,7 @@ Timer::~Timer() { bool Timer::Refresh() { if (timerController.IsRunning()) { uint32_t seconds = timerController.GetTimeRemaining() / 1000; - lv_label_set_text_fmt(time, "%02d:%02d", seconds / 60, seconds % 60); + lv_label_set_text_fmt(time, "%02lu:%02lu", seconds / 60, seconds % 60); } return running; } |
