summaryrefslogtreecommitdiff
path: root/src/gui/npcdialog.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/npcdialog.cpp')
-rw-r--r--src/gui/npcdialog.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/gui/npcdialog.cpp b/src/gui/npcdialog.cpp
index 0ad9e959..4efa29eb 100644
--- a/src/gui/npcdialog.cpp
+++ b/src/gui/npcdialog.cpp
@@ -586,6 +586,11 @@ void NpcEventListener::event(Event::Channel channel,
dialog->showNextButton();
}
+ else if (event.getType() == Event::ClearDialog)
+ {
+ if (NpcDialog *dialog = getDialog(event.getInt("id"), false))
+ dialog->setText(std::string());
+ }
else if (event.getType() == Event::Close)
{
int id = event.getInt("id");
@@ -600,6 +605,11 @@ void NpcEventListener::event(Event::Channel channel,
dialog->showCloseButton();
}
+ else if (event.getType() == Event::CloseDialog)
+ {
+ if (NpcDialog *dialog = getDialog(event.getInt("id"), false))
+ dialog->setVisible(false);
+ }
else if (event.getType() == Event::CloseAll)
{
NpcDialog::closeAll();