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/event.cpp | |
parent | 3dd1baab3fb00a3aa99447430f16a431a205c614 (diff) | |
download | mana-5727a2d9eeb0688a16e5b7fe32f6d9836c4f7a4e.tar.gz mana-5727a2d9eeb0688a16e5b7fe32f6d9836c4f7a4e.tar.bz2 mana-5727a2d9eeb0688a16e5b7fe32f6d9836c4f7a4e.tar.xz mana-5727a2d9eeb0688a16e5b7fe32f6d9836c4f7a4e.zip |
Have the event system channels use enums instead of strings
Reviewed-by: Freeyorp
Diffstat (limited to 'src/event.cpp')
-rw-r--r-- | src/event.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/event.cpp b/src/event.cpp index 3ca4c5e2..c8de2ffd 100644 --- a/src/event.cpp +++ b/src/event.cpp @@ -215,7 +215,7 @@ bool Event::hasActor(const std::string &key) const // Triggers -void Event::trigger(const std::string &channel, const Event &event) +void Event::trigger(Channels channel, const Event &event) { ListenMap::iterator it = mBindings.find(channel); @@ -232,12 +232,12 @@ void Event::trigger(const std::string &channel, const Event &event) } } -void Event::bind(Listener *listener, const std::string &channel) +void Event::bind(Listener *listener, Channels channel) { mBindings[channel].insert(listener); } -void Event::unbind(Listener *listener, const std::string &channel) +void Event::unbind(Listener *listener, Channels channel) { mBindings[channel].erase(listener); } |