diff options
author | Chuck Miller <shadowmil@gmail.com> | 2010-11-11 21:55:25 -0500 |
---|---|---|
committer | Chuck Miller <shadowmil@gmail.com> | 2010-11-11 22:45:58 -0500 |
commit | 5727a2d9eeb0688a16e5b7fe32f6d9836c4f7a4e (patch) | |
tree | 994cdeb1187a94996ca38c5e274aabaa5f1fec76 /src/net/tmwa/chathandler.cpp | |
parent | 3dd1baab3fb00a3aa99447430f16a431a205c614 (diff) | |
download | mana-client-5727a2d9eeb0688a16e5b7fe32f6d9836c4f7a4e.tar.gz mana-client-5727a2d9eeb0688a16e5b7fe32f6d9836c4f7a4e.tar.bz2 mana-client-5727a2d9eeb0688a16e5b7fe32f6d9836c4f7a4e.tar.xz mana-client-5727a2d9eeb0688a16e5b7fe32f6d9836c4f7a4e.zip |
Have the event system channels use enums instead of strings
Reviewed-by: Freeyorp
Diffstat (limited to 'src/net/tmwa/chathandler.cpp')
-rw-r--r-- | src/net/tmwa/chathandler.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/net/tmwa/chathandler.cpp b/src/net/tmwa/chathandler.cpp index 2b647f68..9529a386 100644 --- a/src/net/tmwa/chathandler.cpp +++ b/src/net/tmwa/chathandler.cpp @@ -86,7 +86,7 @@ void ChatHandler::handleMessage(Net::MessageIn &msg) event.setString("nick", nick); event.setString("error", strprintf(_("Whisper could " "not be sent, %s is offline."), nick.c_str())); - event.trigger("Chat"); + event.trigger(CHANNEL_CHAT); } break; case 0x02: @@ -95,7 +95,7 @@ void ChatHandler::handleMessage(Net::MessageIn &msg) event.setString("nick", nick); event.setString("error", strprintf(_("Whisper could " "not be sent, ignored by %s."), nick.c_str())); - event.Event::trigger("Chat"); + event.Event::trigger(CHANNEL_CHAT); } break; } @@ -118,7 +118,7 @@ void ChatHandler::handleMessage(Net::MessageIn &msg) Mana::Event event("Whisper"); event.setString("nick", nick); event.setString("message", chatMsg); - event.trigger("Chat"); + event.trigger(CHANNEL_CHAT); } } else @@ -180,7 +180,7 @@ void ChatHandler::handleMessage(Net::MessageIn &msg) event.setString("nick", sender_name); event.setInt("beingId", beingId); event.setInt("permissions", perms); - event.trigger("Chat"); + event.trigger(CHANNEL_CHAT); break; } @@ -213,13 +213,13 @@ void ChatHandler::handleMessage(Net::MessageIn &msg) event.setInt("permissions", player_relations.getDefault() & (PlayerRelation::SPEECH_LOG | PlayerRelation::SPEECH_FLOAT)); - event.trigger("Chat"); + event.trigger(CHANNEL_CHAT); } else { Mana::Event event("Announcement"); event.setString("message", chatMsg); - event.trigger("Chat"); + event.trigger(CHANNEL_CHAT); } break; } |