summaryrefslogtreecommitdiff
path: root/src/gui/inventorywindow.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/inventorywindow.cpp
parent78ab0ec914d3c5a97f162905afb3dede53f8b9ed (diff)
downloadmana-81cf85e9ec1d37dc6e8dd9883f42bb50dace9135.tar.gz
mana-81cf85e9ec1d37dc6e8dd9883f42bb50dace9135.tar.bz2
mana-81cf85e9ec1d37dc6e8dd9883f42bb50dace9135.tar.xz
mana-81cf85e9ec1d37dc6e8dd9883f42bb50dace9135.zip
Made the Button ctor accept eventId and action listener.
Diffstat (limited to 'src/gui/inventorywindow.cpp')
-rw-r--r--src/gui/inventorywindow.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/gui/inventorywindow.cpp b/src/gui/inventorywindow.cpp
index 5227152c..0c8fb14e 100644
--- a/src/gui/inventorywindow.cpp
+++ b/src/gui/inventorywindow.cpp
@@ -50,19 +50,14 @@ InventoryWindow::InventoryWindow():
setMinHeight(172);
setDefaultSize(115, 25, 322, 172);
- useButton = new Button("Use");
- dropButton = new Button("Drop");
+ useButton = new Button("Use", "use", this);
+ dropButton = new Button("Drop", "drop", this);
items = new ItemContainer(player_node->mInventory.get());
invenScroll = new ScrollArea(items);
invenScroll->setPosition(8, 8);
invenScroll->setHorizontalScrollPolicy(gcn::ScrollArea::SHOW_NEVER);
- useButton->setEventId("use");
- dropButton->setEventId("drop");
- useButton->addActionListener(this);
- dropButton->addActionListener(this);
-
itemNameLabel = new gcn::Label("Name:");
itemDescriptionLabel = new gcn::Label("Description:");
itemEffectLabel = new gcn::Label("Effect:");