From 904161fdba32468ff4d97d9533e62809131ed1a2 Mon Sep 17 00:00:00 2001 From: w00t Date: Mon, 4 Aug 2008 15:28:29 +0000 Subject: Add Channel::SetTopic(User *, std::string &) to set topic on a channel. Use it in CommandTopic. Also modify OnLocalTopicChange to accept a new return value. (0 == proceed as normal, 1 == don't check anything, -1 == disallow change silently). git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10082 e03df62e-2008-0410-955e-edbf42e46eb7 --- include/channels.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include/channels.h') diff --git a/include/channels.h b/include/channels.h index c27329310..605ac8216 100644 --- a/include/channels.h +++ b/include/channels.h @@ -232,6 +232,12 @@ class CoreExport Channel : public Extensible */ std::string GetModeParameter(char mode); + /** Sets the channel topic. + * @param u The user setting the topic + * @param t The topic to set it to. Non-const, as it may be modified by a hook. + */ + int SetTopic(User *u, std::string &t); + /** Obtain the channel "user counter" * This returns the channel reference counter, which is initialized * to 0 when the channel is created and incremented/decremented -- cgit v1.2.3