diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-10-29 22:45:05 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-10-29 22:45:05 +0300 |
commit | 24179041d619875bda96eb94307b1f3dd64e6add (patch) | |
tree | c1abcdc54b6e505f70aa1cf9a772560a8ebddfca /src/gui/widgets/tabs | |
parent | 52f82ad4439dab8e6ab67ad6aa25fb8d0c8c1683 (diff) | |
download | manaverse-24179041d619875bda96eb94307b1f3dd64e6add.tar.gz manaverse-24179041d619875bda96eb94307b1f3dd64e6add.tar.bz2 manaverse-24179041d619875bda96eb94307b1f3dd64e6add.tar.xz manaverse-24179041d619875bda96eb94307b1f3dd64e6add.zip |
fix char replacment in whispers for sender.
Before whisper sender not saw replaced text in chat.
Diffstat (limited to 'src/gui/widgets/tabs')
-rw-r--r-- | src/gui/widgets/tabs/whispertab.cpp | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/src/gui/widgets/tabs/whispertab.cpp b/src/gui/widgets/tabs/whispertab.cpp index 7ad14ac65..58849b623 100644 --- a/src/gui/widgets/tabs/whispertab.cpp +++ b/src/gui/widgets/tabs/whispertab.cpp @@ -51,20 +51,17 @@ WhisperTab::~WhisperTab() void WhisperTab::handleInput(const std::string &msg) { + std::string newMsg; if (chatWindow) - { - Net::getChatHandler()->privateMessage(mNick, - chatWindow->doReplace(msg)); - } + newMsg = chatWindow->doReplace(msg); else - { - Net::getChatHandler()->privateMessage(mNick, msg); - } + newMsg = msg; + Net::getChatHandler()->privateMessage(mNick, newMsg); if (player_node) - chatLog(player_node->getName(), msg); + chatLog(player_node->getName(), newMsg); else - chatLog("?", msg); + chatLog("?", newMsg); } void WhisperTab::handleCommand(const std::string &msg) |