summaryrefslogtreecommitdiff
path: root/src/gui/npcdialog.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-06-13 00:43:25 +0300
committerAndrei Karas <akaras@inbox.ru>2013-06-13 00:43:25 +0300
commit9233c3936657f6dc4ca9c73d84ea8c045b3fc09d (patch)
treea7def2f0e6c8fcdaefd6f0f330da7e7eb6c9c0b0 /src/gui/npcdialog.cpp
parentd3af59b8eedae98a49367e2ac37f2ab1b79c0557 (diff)
downloadmanaplus-9233c3936657f6dc4ca9c73d84ea8c045b3fc09d.tar.gz
manaplus-9233c3936657f6dc4ca9c73d84ea8c045b3fc09d.tar.bz2
manaplus-9233c3936657f6dc4ca9c73d84ea8c045b3fc09d.tar.xz
manaplus-9233c3936657f6dc4ca9c73d84ea8c045b3fc09d.zip
move npc dialogs array from netcode.
Diffstat (limited to 'src/gui/npcdialog.cpp')
-rw-r--r--src/gui/npcdialog.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/gui/npcdialog.cpp b/src/gui/npcdialog.cpp
index f4d99cc79..2271a0bc7 100644
--- a/src/gui/npcdialog.cpp
+++ b/src/gui/npcdialog.cpp
@@ -66,6 +66,7 @@
#define CAPTION_SUBMIT _("Submit")
NpcDialog::DialogList NpcDialog::instances;
+NpcDialogs NpcDialog::mNpcDialogs;
typedef std::vector<Image *>::iterator ImageVectorIter;
@@ -774,3 +775,15 @@ void NpcDialog::clearRows()
{
mTextBox->clearRows();
}
+
+void NpcDialog::clearDialogs()
+{
+ NpcDialogs::iterator it = mNpcDialogs.begin();
+ const NpcDialogs::iterator it_end = mNpcDialogs.end();
+ while (it != it_end)
+ {
+ delete (*it).second;
+ ++ it;
+ }
+ mNpcDialogs.clear();
+}