mirror of
https://github.com/InfiniTimeOrg/InfiniTime.git
synced 2024-11-30 12:42:55 +03:00
Correct tick overflow handling for timer reset
This commit is contained in:
parent
f1651c8000
commit
dd3de923e6
@ -105,7 +105,7 @@ void Timer::UpdateMask() {
|
|||||||
void Timer::Refresh() {
|
void Timer::Refresh() {
|
||||||
if (timer.IsRunning()) {
|
if (timer.IsRunning()) {
|
||||||
DisplayTime();
|
DisplayTime();
|
||||||
} else if (buttonPressing && xTaskGetTickCount() > pressTime + pdMS_TO_TICKS(150)) {
|
} else if (buttonPressing && xTaskGetTickCount() - pressTime > pdMS_TO_TICKS(150)) {
|
||||||
lv_label_set_text_static(txtPlayPause, "Reset");
|
lv_label_set_text_static(txtPlayPause, "Reset");
|
||||||
maskPosition += 15;
|
maskPosition += 15;
|
||||||
if (maskPosition > 240) {
|
if (maskPosition > 240) {
|
||||||
|
Loading…
Reference in New Issue
Block a user