Foundation classes for a basic GUI implementing simple widgets and events

Dependents:   TouchScreenGUIDemo

Revision:
12:63db16fea709
Parent:
8:a460cabc85ac
Child:
15:e69fd74d42e4
--- a/Events/EventListener.h	Fri Apr 22 16:12:42 2016 +0000
+++ b/Events/EventListener.h	Sun May 08 14:42:08 2016 +0000
@@ -5,26 +5,23 @@
 class EventListener;
 
 #include "EventHandler.h"
+#include "LinkedList.h"
 
-class EventListener {
-    
-    public:
-    
+class EventListener
+{
+
+public:
+
     EventListener();
-    
+
     virtual bool isEventTarget(Event e);
     void handleEvent(Event e);
-    void setEventHandler(uint8_t type, EventHandler handler);
-    /**
-    * Returns the number of remaining handlers
-    **/
-    int unsetEventHandler(uint8_t type);
-   
-    private:
-    
-    EventHandlerWrapper* _handlers;
-    int _numHandlers;  
-      
+    void setEventHandler(EventHandler *handler);
+    void unsetEventHandler(EventHandler* handler);
+
+private:
+
+    LinkedList<EventHandler> _handlers;
 };
-    
+
 #endif
\ No newline at end of file