1
0
Fork 0

Make new notifications refresh idle timer

This commit is contained in:
Federico Igne 2021-09-07 20:38:48 +01:00
parent 91b2e50252
commit 59ce48a3f3

View file

@ -250,9 +250,10 @@ void SystemTask::Work() {
isDimmed = false;
break;
case Messages::TouchWakeUp: {
if(touchHandler.GetNewTouchInfo()) {
if (touchHandler.GetNewTouchInfo()) {
auto gesture = touchHandler.GestureGet();
if (gesture != Pinetime::Drivers::Cst816S::Gestures::None and ((gesture == Pinetime::Drivers::Cst816S::Gestures::DoubleTap and
if (gesture != Pinetime::Drivers::Cst816S::Gestures::None and
((gesture == Pinetime::Drivers::Cst816S::Gestures::DoubleTap and
settingsController.isWakeUpModeOn(Pinetime::Controllers::Settings::WakeUpMode::DoubleTap)) or
(gesture == Pinetime::Drivers::Cst816S::Gestures::SingleTap and
settingsController.isWakeUpModeOn(Pinetime::Controllers::Settings::WakeUpMode::SingleTap)))) {
@ -276,6 +277,8 @@ void SystemTask::Work() {
if (settingsController.GetNotificationStatus() == Pinetime::Controllers::Settings::Notification::ON) {
if (isSleeping && !isWakingUp) {
GoToRunning();
} else {
ReloadIdleTimer();
}
displayApp.PushMessage(Pinetime::Applications::Display::Messages::NewNotification);
}