diff options
| author | JF <jf@codingfield.com> | 2021-06-20 15:09:24 (GMT) |
|---|---|---|
| committer | Gitea <gitea@fake.local> | 2021-06-20 15:09:24 (GMT) |
| commit | d96395c81021778af35b8b4bf965bfe8663eb081 (patch) | |
| tree | 979e75d716bca8bcd69b86f24a2f2d0270a274d0 /src/components/timer/TimerController.h | |
| parent | fb133a0167f7ea4281bca45be6efc928720d4f82 (diff) | |
| parent | 20a24f8cf56551eae1202f8dc5733bd0cf61adbf (diff) | |
Merge branch 'develop' of JF/PineTime into master
Diffstat (limited to 'src/components/timer/TimerController.h')
| -rw-r--r-- | src/components/timer/TimerController.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/components/timer/TimerController.h b/src/components/timer/TimerController.h index 5a0b293..fa7bc90 100644 --- a/src/components/timer/TimerController.h +++ b/src/components/timer/TimerController.h @@ -12,7 +12,7 @@ namespace Pinetime { class TimerController { public: - TimerController(Pinetime::System::SystemTask& systemTask); + TimerController() = default; void Init(); @@ -23,12 +23,13 @@ namespace Pinetime { uint32_t GetTimeRemaining(); bool IsRunning(); - + + void OnTimerEnd(); + + void Register(System::SystemTask* systemTask); + private: - System::SystemTask& systemTask; - - static void timerEnd(void* p_context); - + System::SystemTask* systemTask = nullptr; TickType_t endTicks; bool timerRunning = false; }; |
