From 39c36efc9de6f31d64b6e0b5376989887b7e72e5 Mon Sep 17 00:00:00 2001 From: Tom Leese Date: Tue, 7 Aug 2012 10:56:58 +0100 Subject: Fixed issue where previous special entries were drawn underneath Reviewed-by: Erik Schilling. --- src/gui/specialswindow.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/gui/specialswindow.cpp b/src/gui/specialswindow.cpp index 53106da2..d96b5805 100644 --- a/src/gui/specialswindow.cpp +++ b/src/gui/specialswindow.cpp @@ -160,6 +160,13 @@ void SpecialsWindow::draw(gcn::Graphics *graphics) void SpecialsWindow::rebuild(const std::map &specialData) { + // remove current entries so they don't get drawn underneath + for (std::map::const_iterator it = mEntries.begin(); + it != mEntries.end(); ++it) + { + remove(it->second); + } + make_dtor(mEntries); mEntries.clear(); int vPos = 0; //vertical position of next placed element -- cgit v1.2.3-70-g09d2