diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-03-22 22:22:15 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-03-22 23:21:10 +0300 |
commit | 6b92425b46de741d4cda35027083fd988ac4e942 (patch) | |
tree | 4ea1b96d494d267ed3ceb835d611d4b095bc51f7 /src/gui/chatwindow.cpp | |
parent | 0fcce97fe86721f4b426250a32f461ad951f6d99 (diff) | |
download | ManaVerse-6b92425b46de741d4cda35027083fd988ac4e942.tar.gz ManaVerse-6b92425b46de741d4cda35027083fd988ac4e942.tar.bz2 ManaVerse-6b92425b46de741d4cda35027083fd988ac4e942.tar.xz ManaVerse-6b92425b46de741d4cda35027083fd988ac4e942.zip |
Add option to accept language messages in any languge.
This messages will be showed in language or general tab.
Diffstat (limited to 'src/gui/chatwindow.cpp')
-rw-r--r-- | src/gui/chatwindow.cpp | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/src/gui/chatwindow.cpp b/src/gui/chatwindow.cpp index 074ce2b81..f6035c5dc 100644 --- a/src/gui/chatwindow.cpp +++ b/src/gui/chatwindow.cpp @@ -267,6 +267,7 @@ ChatWindow::ChatWindow(): mAutoHide = config.getBoolValue("autohideChat"); mShowBattleEvents = config.getBoolValue("showBattleEvents"); + mShowAllLang = serverConfig.getValue("showAllLang", 0); enableVisibleSound(true); } @@ -1479,10 +1480,25 @@ void ChatWindow::resortChatLog(std::string line, Own own, } } - if (langChatTab && !channel.empty() - && langChatTab->getChannelName() == channel) + if (langChatTab && !channel.empty()) { - langChatTab->chatLog(line, own, ignoreRecord, tryRemoveColors); + if (langChatTab->getChannelName() == channel) + { + langChatTab->chatLog(line, own, ignoreRecord, tryRemoveColors); + } + else if (mShowAllLang) + { + if (langChatTab) + { + langChatTab->chatLog(prefix + line, own, + ignoreRecord, tryRemoveColors); + } + else if (localChatTab) + { + localChatTab->chatLog(prefix + line, own, + ignoreRecord, tryRemoveColors); + } + } } else if (localChatTab && channel.empty()) { |