summaryrefslogtreecommitdiff
path: root/src/modes.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2014-04-20 14:35:14 -0400
committerAdam <Adam@anope.org>2014-04-20 14:35:14 -0400
commit26ac315192e0d8a04d50e910697ab794eedf0cc1 (patch)
treeb9916f14fe35ce5c4de95c4194ca4ea0cb30812f /src/modes.cpp
parent0b6476f06ff9ce06545c421143c7d7163c750aa5 (diff)
New event system
Diffstat (limited to 'src/modes.cpp')
-rw-r--r--src/modes.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/modes.cpp b/src/modes.cpp
index 13cda797f..c8908820c 100644
--- a/src/modes.cpp
+++ b/src/modes.cpp
@@ -14,6 +14,7 @@
#include "protocol.h"
#include "channels.h"
#include "uplink.h"
+#include "event.h"
struct StackerInfo;
@@ -138,7 +139,7 @@ ChannelMode::ChannelMode(const Anope::string &cm, char mch) : Mode(cm, MC_CHANNE
bool ChannelMode::CanSet(User *u) const
{
EventReturn MOD_RESULT;
- FOREACH_RESULT(OnCanSet, MOD_RESULT, (u, this));
+ MOD_RESULT = Event::OnCanSet(&Event::CanSet::OnCanSet, u, this);
return MOD_RESULT != EVENT_STOP;
}
@@ -335,7 +336,7 @@ bool ModeManager::AddUserMode(UserMode *um)
UserModesByName[um->name] = um;
- FOREACH_MOD(OnUserModeAdd, (um));
+ Event::OnUserModeAdd(&Event::UserModeAdd::OnUserModeAdd, um);
return true;
}
@@ -369,7 +370,7 @@ bool ModeManager::AddChannelMode(ChannelMode *cm)
ChannelModesByName[cm->name] = cm;
- FOREACH_MOD(OnChannelModeAdd, (cm));
+ Event::OnChannelModeAdd(&Event::ChannelModeAdd::OnChannelModeAdd, cm);
return true;
}