diff options
author | Björn Steinbrink <B.Steinbrink@gmx.de> | 2006-03-08 19:13:26 +0000 |
---|---|---|
committer | Björn Steinbrink <B.Steinbrink@gmx.de> | 2006-03-08 19:13:26 +0000 |
commit | 405c23831a4e1363f26f848215c8140f6d6d9f78 (patch) | |
tree | edf8b8838f055a1b5d024a3976b49f5cddfa8c50 /src/gui/windowcontainer.cpp | |
parent | e645ad2a139c332937813dd2a1e5424ded182e26 (diff) | |
download | mana-client-405c23831a4e1363f26f848215c8140f6d6d9f78.tar.gz mana-client-405c23831a4e1363f26f848215c8140f6d6d9f78.tar.bz2 mana-client-405c23831a4e1363f26f848215c8140f6d6d9f78.tar.xz mana-client-405c23831a4e1363f26f848215c8140f6d6d9f78.zip |
Added a 'dtor' helper functor to delete objects in arrays and containers using STL algorithms.
Diffstat (limited to 'src/gui/windowcontainer.cpp')
-rw-r--r-- | src/gui/windowcontainer.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gui/windowcontainer.cpp b/src/gui/windowcontainer.cpp index 3803b652..14aaaf68 100644 --- a/src/gui/windowcontainer.cpp +++ b/src/gui/windowcontainer.cpp @@ -23,11 +23,11 @@ #include "windowcontainer.h" +#include "../utils/dtor.h" + void WindowContainer::logic() { - for (WidgetIterator i = mDeathList.begin(); i != mDeathList.end(); i++) { - delete (*i); - } + for_each(mDeathList.begin(), mDeathList.end(), make_dtor(mDeathList)); mDeathList.clear(); gcn::Container::logic(); |