summaryrefslogtreecommitdiff
path: root/src/gui/questswindow.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-02-26 00:01:56 +0300
committerAndrei Karas <akaras@inbox.ru>2013-02-26 00:01:56 +0300
commit803b6afd00b0e3574b40b866f21a0d3d01f6dc4d (patch)
tree8a55ef881f1eaac4d216b3f5d2c4605eb520070d /src/gui/questswindow.cpp
parent8478d540748edccf36dc9bda5f0c3de0aa7bf763 (diff)
downloadmanaplus-803b6afd00b0e3574b40b866f21a0d3d01f6dc4d.tar.gz
manaplus-803b6afd00b0e3574b40b866f21a0d3d01f6dc4d.tar.bz2
manaplus-803b6afd00b0e3574b40b866f21a0d3d01f6dc4d.tar.xz
manaplus-803b6afd00b0e3574b40b866f21a0d3d01f6dc4d.zip
Improve string usage in other files.
Diffstat (limited to 'src/gui/questswindow.cpp')
-rw-r--r--src/gui/questswindow.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gui/questswindow.cpp b/src/gui/questswindow.cpp
index 164f3ce26..076e042f9 100644
--- a/src/gui/questswindow.cpp
+++ b/src/gui/questswindow.cpp
@@ -393,7 +393,7 @@ void QuestsWindow::rebuild(const bool playSound)
void QuestsWindow::showQuest(const QuestItem *const quest)
{
- if (!quest)
+ if (!quest || !translator)
return;
const std::vector<QuestItemText> &texts = quest->texts;
@@ -409,7 +409,8 @@ void QuestsWindow::showQuest(const QuestItem *const quest)
mText->addRow(translator->getStr(data.text));
break;
case QUEST_NAME:
- mText->addRow("[" + translator->getStr(data.text) + "]");
+ mText->addRow(std::string("[").append(translator->getStr(
+ data.text)).append("]"));
break;
}
}