refactored InputName

This commit is contained in:
Jonas Zeunert
2018-05-31 17:42:43 +02:00
parent 2321f2997f
commit 01b0d990f3
8 changed files with 60 additions and 55 deletions

View File

@@ -26,17 +26,17 @@
namespace Input
{
class InputEventHandler
class EventHandler
{
public:
void handle(InputEvent& event);
void handle(Event& event);
};
class Detector
{
public:
Detector(InputGPIOInterface* in_gpio_interface, std::map<char, InputEvent> events, InputEventNotifier* input_event_notifier);
Detector(InputGPIOInterface* input_gpio_interface, std::map<char, Event> events, EventNotifier* event_notifier);
~Detector();
private:
@@ -44,11 +44,11 @@ private:
bool check_inputs(char& address);
private:
InputGPIOInterface* in_gpio_interface;
InputGPIOInterface* input_gpio_interface;
std::map<char, InputEvent> input_events;
std::map<char, Event> events;
InputEventNotifier* input_event_notifier;
EventNotifier* event_notifier;
bool is_running;
std::thread detect_thread;