1
0
Fork 0
InfiniTime/src/displayapp
Kozova1 57b3397078
Multiple wakeup sources (#290)
* Allow multiple wakeup modes at the same time.

This commit adds multiple wakeup modes support.
It does so by storing them as a uint8_t bitfield enum.
It changes the following functions:

Since multiple modes can be on now, older version would not cut it:
WakeUpMode getWakeupMode() -> std::bitset<3> getWakeUpModes()
Where each bit corresponds to a WakeUpMode

We still need a way to check whether a specific wakeup mode is on, so:
bool isWakeUpModeOn(const WakeUpMode mode)

This function was changed to work correctly with the new implementation.
setWakeUpMode(WakeupMode mode, bool enable)

Previously, systemtask would exit SystemTask::OnTouchEvent() if the wake
up mode was None or RaiseWrist, to prevent waking up when a touch was
received. However, after enabling using multiple WakeUpModes, this
caused a bug where when RaiseWrist was checked with SingleTap or
DoubleTap, the tap detection wouldn't work.

This commit fixes that bug.

Next commit will update the settings WakeUpMode select UI to reflect these changes.

Signed-off-by: Kozova1 <mug66kk@gmail.com>

* Updated UI to reflect multiple WakeUp sources being available.

Signed-off-by: Kozova1 <mug66kk@gmail.com>
2021-07-14 20:51:51 +02:00
..
fonts and metronome icon (#439) 2021-07-02 17:34:32 +02:00
icons Big UI and navigation Rewrite 2021-04-04 03:08:51 +01:00
screens Multiple wakeup sources (#290) 2021-07-14 20:51:51 +02:00
Apps.h add basic metronome app (#409) 2021-06-12 15:06:58 +02:00
DisplayApp.cpp Set correct refresh times for lvgl (#488) 2021-07-14 20:35:21 +02:00
DisplayApp.h Adjust displayapp delay to compensate time spent (#482) 2021-07-13 20:42:59 +02:00
DisplayAppRecovery.cpp Move most of the code from the constructor of the objects statically initialized in main() into Start()/Init() functions to avoid Static Initialization Order Fiasco (https://en.cppreference.com/w/cpp/language/siof). See https://github.com/JF002/InfiniTime/pull/415#issuecomment-859004238. 2021-06-12 10:58:28 +02:00
DisplayAppRecovery.h Fix build for recovery firmware. 2021-06-06 20:20:55 +02:00
DummyLittleVgl.h Add Init() in DummyuLittleVgl to fix recovery firmware 2021-06-12 18:00:42 +02:00
LittleVgl.cpp Move most of the code from the constructor of the objects statically initialized in main() into Start()/Init() functions to avoid Static Initialization Order Fiasco (https://en.cppreference.com/w/cpp/language/siof). See https://github.com/JF002/InfiniTime/pull/415#issuecomment-859004238. 2021-06-12 10:58:28 +02:00
LittleVgl.h Move most of the code from the constructor of the objects statically initialized in main() into Start()/Init() functions to avoid Static Initialization Order Fiasco (https://en.cppreference.com/w/cpp/language/siof). See https://github.com/JF002/InfiniTime/pull/415#issuecomment-859004238. 2021-06-12 10:58:28 +02:00
lv_pinetime_theme.c add basic metronome app (#409) 2021-06-12 15:06:58 +02:00
lv_pinetime_theme.h Reformatted all the files according to clang-format style 2021-04-24 11:39:53 +03:00
Messages.h Timer App (#355) 2021-05-20 20:43:54 +02:00
TouchEvents.h Reformatted all the files according to clang-format style 2021-04-24 11:39:53 +03:00