@@ -102,9 +102,7 @@ SystemTask::SystemTask(Drivers::SpiMaster& spi,
102
102
spiNorFlash,
103
103
heartRateController,
104
104
motionController,
105
- fs),
106
- wokenBy {WokenBy::Other},
107
- ignoreNextTouchEvent {false } {
105
+ fs) {
108
106
}
109
107
110
108
void SystemTask::Start () {
@@ -267,7 +265,8 @@ void SystemTask::Work() {
267
265
break ;
268
266
}
269
267
case Messages::GoToSleep:
270
- displayApp.HideIgnoreTouchPopup (true );
268
+ ignoreTouchPopupHidden = true ;
269
+ displayApp.PushMessage (Pinetime::Applications::Display::Messages::HideIgnoreTouchPopup);
271
270
if (doNotGoToSleep) {
272
271
break ;
273
272
}
@@ -362,14 +361,16 @@ void SystemTask::Work() {
362
361
// if we get to here TouchEvents is allowed and the "ButtonUnlocks" requirement can be overridden
363
362
wokenBy = WokenBy::Other;
364
363
} else {
365
- displayApp.HideIgnoreTouchPopup (false );
364
+ ignoreTouchPopupHidden = false ;
365
+ displayApp.PushMessage (Pinetime::Applications::Display::Messages::ShowIgnoreTouchPopup);
366
366
}
367
367
break ;
368
368
case Messages::HandleButtonEvent: {
369
369
// if the IgnoreTouchPopup is active the first button event unlocks the device
370
- if (!displayApp. IsIgnoreTouchPopupHidden () ) {
370
+ if (!ignoreTouchPopupHidden ) {
371
371
wokenBy = WokenBy::Button ;
372
- displayApp.HideIgnoreTouchPopup (true );
372
+ ignoreTouchPopupHidden = true ;
373
+ displayApp.PushMessage (Pinetime::Applications::Display::Messages::HideIgnoreTouchPopup);
373
374
break ;
374
375
}
375
376
Controllers::ButtonActions action;
0 commit comments