summaryrefslogtreecommitdiff
path: root/src/gui/item_amount.cpp
diff options
context:
space:
mode:
authorJared Adams <jaxad0127@gmail.com>2009-03-08 18:40:48 -0600
committerIra Rice <irarice@gmail.com>2009-03-09 00:52:56 -0600
commit5fa3f62d0d6d9cbffeef0f6a2497aae023dbadcf (patch)
treea905c74e059311b5adf10a6eacbe53482d95c380 /src/gui/item_amount.cpp
parent6ea994477c58912785729e7922eb90862a1ab13c (diff)
downloadmana-5fa3f62d0d6d9cbffeef0f6a2497aae023dbadcf.tar.gz
mana-5fa3f62d0d6d9cbffeef0f6a2497aae023dbadcf.tar.bz2
mana-5fa3f62d0d6d9cbffeef0f6a2497aae023dbadcf.tar.xz
mana-5fa3f62d0d6d9cbffeef0f6a2497aae023dbadcf.zip
Add an interface for eAthena's storage system
Diffstat (limited to 'src/gui/item_amount.cpp')
-rw-r--r--src/gui/item_amount.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/gui/item_amount.cpp b/src/gui/item_amount.cpp
index 8ab36df0..05dca472 100644
--- a/src/gui/item_amount.cpp
+++ b/src/gui/item_amount.cpp
@@ -24,6 +24,7 @@
#include "inttextfield.h"
#include "item_amount.h"
#include "slider.h"
+#include "storagewindow.h"
#include "trade.h"
#include "widgets/layout.h"
@@ -81,6 +82,14 @@ ItemAmountWindow::ItemAmountWindow(int usage, Window *parent, Item *item):
setCaption(_("Select amount of items to drop."));
okButton->setActionEventId("Drop");
break;
+ case AMOUNT_STORE_ADD:
+ setCaption(_("Select amount of items to store."));
+ okButton->setActionEventId("AddStore");
+ break;
+ case AMOUNT_STORE_REMOVE:
+ setCaption(_("Select amount of items to remove from storage."));
+ okButton->setActionEventId("RemoveStore");
+ break;
default:
break;
}
@@ -124,6 +133,16 @@ void ItemAmountWindow::action(const gcn::ActionEvent &event)
tradeWindow->tradeItem(mItem, mItemAmountTextField->getValue());
scheduleDelete();
}
+ else if (event.getId() == "AddStore")
+ {
+ storageWindow->addStore(mItem, mItemAmountTextField->getValue());
+ scheduleDelete();
+ }
+ else if (event.getId() == "RemoveStore")
+ {
+ storageWindow->removeStore(mItem, mItemAmountTextField->getValue());
+ scheduleDelete();
+ }
mItemAmountTextField->setValue(amount);
mItemAmountSlide->setValue(amount);
}