aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Sulfrian <alexander@sulfrian.net>2010-05-09 19:28:13 +0200
committerAlexander Sulfrian <alexander@sulfrian.net>2013-01-05 17:17:48 +0100
commit2390e4c01835506f53e80c796ed360befd768c3b (patch)
treef77c0e24d72d89dbb15ba1cec986cf14563a982e
parent1d595f048c9e59bbff14217e2fe3821ee3e1aaa1 (diff)
downloadusdx-2390e4c01835506f53e80c796ed360befd768c3b.tar.gz
usdx-2390e4c01835506f53e80c796ed360befd768c3b.tar.xz
usdx-2390e4c01835506f53e80c796ed360befd768c3b.zip
before set the background of a frame, free old one
Diffstat (limited to '')
-rw-r--r--src/menu/frame.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/menu/frame.cpp b/src/menu/frame.cpp
index 08cc833a..7c05a146 100644
--- a/src/menu/frame.cpp
+++ b/src/menu/frame.cpp
@@ -48,6 +48,10 @@ namespace usdx
void Frame::set_background(FrameBackground* background)
{
+ if (this->background) {
+ delete this->background;
+ }
+
this->background = background;
}