diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-05-16 16:15:34 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-05-16 16:15:34 +0300 |
commit | fe6a120ea38daaad39f6952a886c20269cfedca6 (patch) | |
tree | 4595d63a2ab9764873657182fbf2ab2b985474bf /src/gui/windows/chatwindow.h | |
parent | 6279b10249efa59b3161b014899465fe4bb08da4 (diff) | |
download | mv-fe6a120ea38daaad39f6952a886c20269cfedca6.tar.gz mv-fe6a120ea38daaad39f6952a886c20269cfedca6.tar.bz2 mv-fe6a120ea38daaad39f6952a886c20269cfedca6.tar.xz mv-fe6a120ea38daaad39f6952a886c20269cfedca6.zip |
Move chatmsgtype into separate file.
Diffstat (limited to 'src/gui/windows/chatwindow.h')
-rw-r--r-- | src/gui/windows/chatwindow.h | 22 |
1 files changed, 6 insertions, 16 deletions
diff --git a/src/gui/windows/chatwindow.h b/src/gui/windows/chatwindow.h index 98b1eb73e..b90b15b45 100644 --- a/src/gui/windows/chatwindow.h +++ b/src/gui/windows/chatwindow.h @@ -23,6 +23,8 @@ #ifndef GUI_WINDOWS_CHATWINDOW_H #define GUI_WINDOWS_CHATWINDOW_H +#include "gui/chatmsgtype.h" + #include "gui/widgets/window.h" #include "listeners/actionlistener.h" @@ -46,19 +48,6 @@ class WhisperTab; const int DEFAULT_CHAT_WINDOW_SCROLL = 7; -enum Own -{ - BY_GM = 0, - BY_PLAYER, - BY_OTHER, - BY_SERVER, - BY_CHANNEL, - ACT_WHISPER, // getting whispered at - ACT_IS, // equivalent to "/me" on IRC - BY_LOGGER, - BY_UNKNOWN = -1 -}; - /** * The chat window. * @@ -202,7 +191,7 @@ class ChatWindow final : public Window, void addWhisper(const std::string &restrict nick, const std::string &restrict mes, - const Own own = BY_OTHER); + const ChatMsgType::Type own = ChatMsgType::BY_OTHER); WhisperTab *addWhisperTab(const std::string &nick, const bool switchTo = false) A_WARN_UNUSED; @@ -213,13 +202,14 @@ class ChatWindow final : public Window, void ignoreAllWhispers(); - bool resortChatLog(std::string line, Own own, + bool resortChatLog(std::string line, ChatMsgType::Type own, const std::string &channel, const bool ignoreRecord, const bool tryRemoveColors); static void battleChatLog(const std::string &line, - Own own = BY_UNKNOWN, + ChatMsgType::Type own + = ChatMsgType::BY_UNKNOWN, const bool ignoreRecord = false, const bool tryRemoveColors = true); |