ELEC2645 (2018/19) / Mbed 2 deprecated el17ajf

Dependencies:   mbed

Fork of el17ajf by Angus Findlay

Revision:
13:59e17cab320a
Parent:
12:beb0d7632531
Child:
18:24ce897024d0
--- a/Input/Input.h	Sun Mar 17 12:14:56 2019 +0000
+++ b/Input/Input.h	Mon Mar 18 18:09:57 2019 +0000
@@ -1,16 +1,11 @@
 #include "Gamepad.h"
 
-class Input {
-public:
-    static const int NUMBER_OF_BUTTONS; 
+namespace Input {
     enum Button {LEFT, RIGHT, UP, DOWN};
-    enum State {RELEASED, RELEASED_FRAME, HIT_FRAME, HELD};
-    static void init();
-    static void deinit();
-    static void update();
-    static bool buttonHit(Button button);
-    static bool buttonHeld(Button button);
-private:
-    static State states[4];
-    static Gamepad * gamepad;
-};
\ No newline at end of file
+    
+    void init();
+    void deinit();
+    void update();
+    bool buttonHit(Button button);
+    bool buttonHeld(Button button);
+};