#pragma once #include "interfaces/input.hpp" #include #include #include class UserInputObserver : public IUserInputObserver, public yacppdic::AutoWirable { public: UserInputObserver() noexcept = default; void listen() noexcept override; bool is_key_pressed(Key key) noexcept override; Key get_currently_pressed_key() const noexcept override; void clear_currently_pressed() noexcept override; private: Key _currently_pressed; std::mutex _currently_pressed_mutex; };