summaryrefslogtreecommitdiff
path: root/src/gui/buy.cpp
diff options
context:
space:
mode:
authorBjörn Steinbrink <B.Steinbrink@gmx.de>2006-03-09 02:02:57 +0000
committerBjörn Steinbrink <B.Steinbrink@gmx.de>2006-03-09 02:02:57 +0000
commit81cf85e9ec1d37dc6e8dd9883f42bb50dace9135 (patch)
tree585415bbb85c48fc8fb83cd5f54e1cfe8e988ee7 /src/gui/buy.cpp
parent78ab0ec914d3c5a97f162905afb3dede53f8b9ed (diff)
downloadmana-client-81cf85e9ec1d37dc6e8dd9883f42bb50dace9135.tar.gz
mana-client-81cf85e9ec1d37dc6e8dd9883f42bb50dace9135.tar.bz2
mana-client-81cf85e9ec1d37dc6e8dd9883f42bb50dace9135.tar.xz
mana-client-81cf85e9ec1d37dc6e8dd9883f42bb50dace9135.zip
Made the Button ctor accept eventId and action listener.
Diffstat (limited to 'src/gui/buy.cpp')
-rw-r--r--src/gui/buy.cpp17
1 files changed, 4 insertions, 13 deletions
diff --git a/src/gui/buy.cpp b/src/gui/buy.cpp
index 71f502f2..42c6ff2f 100644
--- a/src/gui/buy.cpp
+++ b/src/gui/buy.cpp
@@ -53,10 +53,10 @@ BuyDialog::BuyDialog(Network *network):
slider = new Slider(1.0);
quantityLabel = new gcn::Label("0");
moneyLabel = new gcn::Label("Price: 0 GP");
- increaseButton = new Button("+");
- decreaseButton = new Button("-");
- buyButton = new Button("Buy");
- quitButton = new Button("Quit");
+ increaseButton = new Button("+", "+", this);
+ decreaseButton = new Button("-", "-", this);
+ buyButton = new Button("Buy", "buy", this);
+ quitButton = new Button("Quit", "quit", this);
itemDescLabel = new gcn::Label("Description:");
itemEffectLabel = new gcn::Label("Effect:");
@@ -89,18 +89,9 @@ BuyDialog::BuyDialog(Network *network):
itemList->setEventId("item");
slider->setEventId("slider");
- increaseButton->setEventId("+");
- decreaseButton->setEventId("-");
- buyButton->setEventId("buy");
- quitButton->setEventId("quit");
itemList->addActionListener(this);
slider->addActionListener(this);
- increaseButton->addActionListener(this);
- decreaseButton->addActionListener(this);
- buyButton->addActionListener(this);
- quitButton->addActionListener(this);
-
add(scrollArea);
add(slider);