From 34fa5627de0a0431ca76f34445c680a76a9a7dc5 Mon Sep 17 00:00:00 2001 From: attilamolnar Date: Sun, 1 Sep 2013 14:25:15 +0200 Subject: Create a base class for prefix modes Move Channel::SetPrefix() into Membership --- src/modules/m_ojoin.cpp | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'src/modules/m_ojoin.cpp') diff --git a/src/modules/m_ojoin.cpp b/src/modules/m_ojoin.cpp index 54c7bfa73..0a5a57f40 100644 --- a/src/modules/m_ojoin.cpp +++ b/src/modules/m_ojoin.cpp @@ -84,16 +84,14 @@ class CommandOjoin : public SplitCommand /** channel mode +Y */ -class NetworkPrefix : public ModeHandler +class NetworkPrefix : public PrefixMode { public: NetworkPrefix(Module* parent, char NPrefix) - : ModeHandler(parent, "official-join", 'Y', PARAM_ALWAYS, MODETYPE_CHANNEL) + : PrefixMode(parent, "official-join", 'Y') { - list = true; prefix = NPrefix; levelrequired = INT_MAX; - m_paramtype = TR_NICK; prefixrank = NETWORK_VALUE; } @@ -106,12 +104,6 @@ class NetworkPrefix : public ModeHandler return MOD_RES_PASSTHRU; } - - ModeAction OnModeChange(User* source, User* dest, Channel* channel, std::string ¶meter, bool adding) - { - return MODEACTION_ALLOW; - } - }; class ModuleOjoin : public Module -- cgit v1.2.3