diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-03-27 18:54:04 +0100 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2009-03-27 18:57:04 +0100 |
commit | 4b70908a529317ce4e57448fe4f4a59e75416537 (patch) | |
tree | a041eeed198708bf5f558f595f716c7814961daf /src/gui/item_amount.h | |
parent | 372f6493d07cbffb601ecb775ebecd51267725cf (diff) | |
download | mana-4b70908a529317ce4e57448fe4f4a59e75416537.tar.gz mana-4b70908a529317ce4e57448fe4f4a59e75416537.tar.bz2 mana-4b70908a529317ce4e57448fe4f4a59e75416537.tar.xz mana-4b70908a529317ce4e57448fe4f4a59e75416537.zip |
Fixed inventory window. Not resizable though.
Resizing of the inventory window may come back later. Also did some more
code cleanups, moving defines to enums, getting rid of eAthena-specific
offset handling (to be done in the network layer), etc.
Mantis-issue: 666
Diffstat (limited to 'src/gui/item_amount.h')
-rw-r--r-- | src/gui/item_amount.h | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/src/gui/item_amount.h b/src/gui/item_amount.h index 344f8c28..24c50290 100644 --- a/src/gui/item_amount.h +++ b/src/gui/item_amount.h @@ -29,12 +29,6 @@ class IntTextField; class Item; -#define AMOUNT_TRADE_ADD 1 -#define AMOUNT_ITEM_DROP 2 -#define AMOUNT_STORE_ADD 3 -#define AMOUNT_STORE_REMOVE 4 -#define AMOUNT_ITEM_SPLIT 5 - /** * Window used for selecting the amount of items to drop, trade or split. * @@ -43,10 +37,19 @@ class Item; class ItemAmountWindow : public Window, public gcn::ActionListener { public: + enum Usage { + TradeAdd, + ItemDrop, + StoreAdd, + StoreRemove, + ItemSplit + }; + /** * Constructor. */ - ItemAmountWindow(int usage, Window *parent, Item *item, int maxRange = 0); + ItemAmountWindow(Usage usage, Window *parent, Item *item, + int maxRange = 0); /** * Called when receiving actions from widget. @@ -67,7 +70,8 @@ class ItemAmountWindow : public Window, public gcn::ActionListener gcn::Label *mItemAmountLabel; /**< Item amount caption. */ Item *mItem; - int mMax, mUsage; + int mMax; + Usage mUsage; /** * Item Amount buttons. |