Adding Macros!
[pierogi] / macros / pirmacropack.h
index 5325229..55c4f77 100644 (file)
@@ -3,16 +3,56 @@
 
 #include <QTreeWidgetItem>
 #include <QString>
+#include <map>
 
 class QTreeWidget;
 class PIRMacro;
 
+typedef std::map<unsigned int, PIRMacro *> ButtonCollection;
+typedef std::map<char, PIRMacro *> KeyboardCollection;
+
 class PIRMacroPack: public QTreeWidgetItem
 {
 public:
   PIRMacroPack(
-    QTreeWidget *parent,
     QString n);
+
+  bool hasButton(
+    unsigned int buttonID);
+
+  void registerButton(
+    unsigned int buttonID,
+    PIRMacro *macro);
+
+  void eraseButton(
+    unsigned int buttonID,
+    PIRMacro *macro);
+
+  QString buttonText(
+    unsigned int buttonID);
+
+  void executeButton(
+    unsigned int buttonID);
+
+  bool hasKey(
+    char key);
+
+  void registerKey(
+    char key,
+    PIRMacro *macro);
+
+  void eraseKey(
+    char key,
+    PIRMacro *macro);
+
+  void executeKey(
+    char key);
+
+  void storeSettings();
+
+private:
+  ButtonCollection buttons;
+  KeyboardCollection keymaps;
 };
 
 #endif // PIRMACROPACK_H