summaryrefslogtreecommitdiff
path: root/src/gui/equipmentwindow.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/equipmentwindow.h')
-rw-r--r--src/gui/equipmentwindow.h40
1 files changed, 38 insertions, 2 deletions
diff --git a/src/gui/equipmentwindow.h b/src/gui/equipmentwindow.h
index 99a3cc60..e42e7b59 100644
--- a/src/gui/equipmentwindow.h
+++ b/src/gui/equipmentwindow.h
@@ -26,14 +26,28 @@
#include "window.h"
+#include <guichan/actionlistener.hpp>
+
+#include "../equipment.h"
+
class Equipment;
+class Image;
+
+/**
+ * Equipment box.
+ */
+struct EquipBox
+{
+ int posX;
+ int posY;
+};
/**
* Equipment dialog.
*
* \ingroup Interface
*/
-class EquipmentWindow : public Window
+class EquipmentWindow : public Window, public gcn::ActionListener
{
public:
/**
@@ -51,10 +65,32 @@ class EquipmentWindow : public Window
*/
void draw(gcn::Graphics *graphics);
+ void action(const gcn::ActionEvent &event);
+
+ void mousePressed(gcn::MouseEvent& mouseEvent);
+
+ enum{
+ // Equipment rules:
+ EQUIP_TORSO_SLOT = 0,
+ EQUIP_ARMS_SLOT = 1,
+ EQUIP_HEAD_SLOT = 2,
+ EQUIP_LEGS_SLOT = 3,
+ EQUIP_FEET_SLOT = 4,
+ EQUIP_RING1_SLOT = 5,
+ EQUIP_RING2_SLOT = 6,
+ EQUIP_NECKLACE_SLOT = 7,
+ EQUIP_FIGHT1_SLOT = 8,
+ EQUIP_FIGHT2_SLOT = 9,
+ EQUIP_PROJECTILE_SLOT = 10
+ };
private:
Equipment *mEquipment;
-};
+ gcn::Button *mUnequip; /**< Button for unequipping. */
+ Image *mBackground; /**< Background Image. */
+ EquipBox mEquipBox[EQUIPMENT_SIZE]; /**< Equipment Boxes. */
+ int mSelected; /**< Index of selected item. */
+};
extern EquipmentWindow *equipmentWindow;
#endif