diff options
author | Jared Adams <jaxad0127@gmail.com> | 2009-03-18 18:41:55 -0600 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2009-03-18 18:42:12 -0600 |
commit | ff3e3d5c6da770391daa4314410e2e716569f7f4 (patch) | |
tree | c752f1a09209b7dd288c88352c5c1a93d3ad4ab8 | |
parent | 87a5e7ff9aab0073a0658b543376622febabc630 (diff) | |
download | mana-ff3e3d5c6da770391daa4314410e2e716569f7f4.tar.gz mana-ff3e3d5c6da770391daa4314410e2e716569f7f4.tar.bz2 mana-ff3e3d5c6da770391daa4314410e2e716569f7f4.tar.xz mana-ff3e3d5c6da770391daa4314410e2e716569f7f4.zip |
A few more fixes in the ItemAmount dialog
-rw-r--r-- | src/gui/item_amount.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/gui/item_amount.cpp b/src/gui/item_amount.cpp index aca7ff52..b440dfc0 100644 --- a/src/gui/item_amount.cpp +++ b/src/gui/item_amount.cpp @@ -55,7 +55,7 @@ ItemAmountWindow::ItemAmountWindow(int usage, Window *parent, Item *item): minusButton->setSize(20, 20); Button *plusButton = new Button("+", "Plus", this); plusButton->setSize(20, 20); - Button *okButton = new Button(_("Ok"), "Drop", this); + Button *okButton = new Button(_("Ok"), "Ok", this); Button *cancelButton = new Button(_("Cancel"), "Cancel", this); Button *addAllButton = new Button(_("All"), "All", this); @@ -144,8 +144,12 @@ void ItemAmountWindow::action(const gcn::ActionEvent &event) } scheduleDelete(); + return; } + if (amount < 0) amount = 0; + else if (amount > mMax) amount = mMax; + mItemAmountTextField->setValue(amount); mItemAmountSlide->setValue(amount); } |