summaryrefslogtreecommitdiff
path: root/src/gui/equipmentwindow.h
diff options
context:
space:
mode:
authorYohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer>2011-01-25 02:31:59 +0100
committerYohann Ferreira <yohann_dot_ferreira_at_orange_dot_efer>2011-01-25 02:31:59 +0100
commit9ba5bdf74be00f6ed9984c161b16698a13d5eec9 (patch)
tree8a5c7bb377f64f7e098a96490fea58eec2d02dac /src/gui/equipmentwindow.h
parentb973c2c9fd718b16ad9dc6e6b082c3f17dc5c98c (diff)
downloadmana-9ba5bdf74be00f6ed9984c161b16698a13d5eec9.tar.gz
mana-9ba5bdf74be00f6ed9984c161b16698a13d5eec9.tar.bz2
mana-9ba5bdf74be00f6ed9984c161b16698a13d5eec9.tar.xz
mana-9ba5bdf74be00f6ed9984c161b16698a13d5eec9.zip
Added a child class to the equipment window specialized for tAthena.
(As requested by Thorbjorn.) Now the foundation to set up per-protocol equipment display is ready.
Diffstat (limited to 'src/gui/equipmentwindow.h')
-rw-r--r--src/gui/equipmentwindow.h46
1 files changed, 35 insertions, 11 deletions
diff --git a/src/gui/equipmentwindow.h b/src/gui/equipmentwindow.h
index a76fa689..a0fa6acb 100644
--- a/src/gui/equipmentwindow.h
+++ b/src/gui/equipmentwindow.h
@@ -59,16 +59,7 @@ class EquipmentWindow : public Window, public gcn::ActionListener
void mousePressed(gcn::MouseEvent& mouseEvent);
- private:
- void mouseExited(gcn::MouseEvent &event);
- void mouseMoved(gcn::MouseEvent &event);
-
- Item *getItem(int x, int y) const;
-
- void setSelected(int index);
-
- Equipment *mEquipment;
-
+ protected:
/**
* Equipment box.
*/
@@ -80,12 +71,45 @@ class EquipmentWindow : public Window, public gcn::ActionListener
EquipBox *mEquipBox; /**< Equipment Boxes. */
+ int mSelected; /**< Index of selected item. */
+ Equipment *mEquipment;
+
+ private:
+ void mouseExited(gcn::MouseEvent &event);
+ void mouseMoved(gcn::MouseEvent &event);
+
+ Item *getItem(int x, int y) const;
+
+ void setSelected(int index);
+
ItemPopup *mItemPopup;
gcn::Button *mUnequip;
+};
+
+namespace TmwAthena {
+
+class TaEquipmentWindow : public EquipmentWindow
+{
+ public:
+ /**
+ * Constructor.
+ */
+ TaEquipmentWindow(Equipment *equipment);
+
+ /**
+ * Destructor.
+ */
+ ~TaEquipmentWindow();
+
+ /**
+ * Draws the equipment window using TmwAthena routine.
+ */
+ void draw(gcn::Graphics *graphics);
- int mSelected; /**< Index of selected item. */
};
+}; // namespace TmwAthena
+
extern EquipmentWindow *equipmentWindow;
#endif