aboutsummaryrefslogtreecommitdiffstats
path: root/src/displayapp/DisplayApp.cpp
diff options
context:
space:
mode:
authormark9064 <30447455+mark9064@users.noreply.github.com>2024-08-22 16:53:18 +0100
committerJF <JF002@users.noreply.github.com>2024-10-27 19:51:01 +0100
commit1808634f0e041ed1c85b69a967207c2cff812d81 (patch)
treefe0c6f7ea9948855446f890359972e4ac636b166 /src/displayapp/DisplayApp.cpp
parentcfaad261dc0b8b1af0a8b33d8289782be2c4e57a (diff)
Clear ongoing taps when going to sleep
Diffstat (limited to 'src/displayapp/DisplayApp.cpp')
-rw-r--r--src/displayapp/DisplayApp.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/displayapp/DisplayApp.cpp b/src/displayapp/DisplayApp.cpp
index 98a28258..5d33f76e 100644
--- a/src/displayapp/DisplayApp.cpp
+++ b/src/displayapp/DisplayApp.cpp
@@ -313,6 +313,10 @@ void DisplayApp::Refresh() {
while (!lv_task_handler()) {
};
}
+ // Clear any ongoing touch pressed events
+ // Without this LVGL gets stuck in the pressed state and will keep refreshing the
+ // display activity timer causing the screen to never sleep after timeout
+ lvgl.ClearTouchState();
if (msg == Messages::GoToAOD) {
lcd.LowPowerOn();
// Record idle entry time