summaryrefslogtreecommitdiff
path: root/src/gui/statuswindow.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2010-06-06 01:09:42 +0300
committerThorbjørn Lindeijer <thorbjorn@lindeijer.nl>2010-06-06 00:29:14 +0200
commitece8fcdd4a17000285052941148afa056e0a40b7 (patch)
treea4056d4950d8fd910b95ce2e2539084b0bf82d2c /src/gui/statuswindow.cpp
parent5bf9f573fd24bc8cbb6d04f17130a0beaf3c3183 (diff)
downloadmana-ece8fcdd4a17000285052941148afa056e0a40b7.tar.gz
mana-ece8fcdd4a17000285052941148afa056e0a40b7.tar.bz2
mana-ece8fcdd4a17000285052941148afa056e0a40b7.tar.xz
mana-ece8fcdd4a17000285052941148afa056e0a40b7.zip
Fix memory leak in statuswindow
Reviewed-by: Thorbjørn Lindeijer
Diffstat (limited to 'src/gui/statuswindow.cpp')
-rw-r--r--src/gui/statuswindow.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gui/statuswindow.cpp b/src/gui/statuswindow.cpp
index 2439a213..ede85133 100644
--- a/src/gui/statuswindow.cpp
+++ b/src/gui/statuswindow.cpp
@@ -50,6 +50,8 @@ class AttrDisplay : public Container
DERIVED, CHANGEABLE, UNKNOWN
};
+ ~AttrDisplay();
+
virtual std::string update();
virtual Type getType() { return UNKNOWN; }
@@ -386,6 +388,11 @@ AttrDisplay::AttrDisplay(int id, const std::string &name):
mLayout = new LayoutHelper(this);
}
+AttrDisplay::~AttrDisplay()
+{
+ delete mLayout;
+}
+
std::string AttrDisplay::update()
{
int base = player_node->getAttributeBase(mId);