From 7d5536e2abca61f503ed68521603bd30700a7e5e Mon Sep 17 00:00:00 2001 From: jacqueline Date: Tue, 3 Oct 2023 10:37:29 +1100 Subject: Generalise the lvgl input driver in preparation for more input methods --- src/ui/include/lvgl_task.hpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'src/ui/include/lvgl_task.hpp') diff --git a/src/ui/include/lvgl_task.hpp b/src/ui/include/lvgl_task.hpp index 4362249b..f212ab9d 100644 --- a/src/ui/include/lvgl_task.hpp +++ b/src/ui/include/lvgl_task.hpp @@ -15,30 +15,27 @@ #include "freertos/timers.h" #include "display.hpp" +#include "encoder_input.hpp" #include "relative_wheel.hpp" #include "screen.hpp" #include "themes.hpp" #include "touchwheel.hpp" -#include "wheel_encoder.hpp" namespace ui { class UiTask { public: static auto Start() -> UiTask*; - ~UiTask(); - // FIXME: Once we have more input devices, this function should accept a more - // generic interface. - auto SetInputDevice(std::shared_ptr dev) -> void; + auto input(std::shared_ptr input) -> void; private: UiTask(); auto Main() -> void; - std::shared_ptr input_device_; + std::shared_ptr input_; std::shared_ptr current_screen_; }; -- cgit v1.2.3