summaryrefslogtreecommitdiff
path: root/src/gui/KeyManager.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/KeyManager.h')
-rw-r--r--src/gui/KeyManager.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/src/gui/KeyManager.h b/src/gui/KeyManager.h
new file mode 100644
index 0000000..1f5f54d
--- /dev/null
+++ b/src/gui/KeyManager.h
@@ -0,0 +1,36 @@
+/*
+ * KeyManager.h
+ *
+ * Created on: May 4, 2011
+ * Author: jakob
+ */
+
+#ifndef KEYMANAGER_H_
+#define KEYMANAGER_H_
+
+#include <set>
+
+namespace vhc {
+
+class Stage;
+
+class KeyManager {
+
+public:
+ KeyManager(Stage& stage);
+ virtual ~KeyManager();
+
+ void press(int key);
+ void release(int key);
+ bool isPressed(int key) const;
+
+private:
+ Stage& stage;
+
+ std::set<int> keys;
+
+};
+
+}
+
+#endif /* KEYMANAGER_H_ */