diff options
author | Sadie Powell <sadie@witchery.services> | 2020-01-03 20:48:07 +0000 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2020-01-03 21:01:52 +0000 |
commit | a9e8e1f03ace24e9dcb50299f8e66c5fd6b42850 (patch) | |
tree | 4396a3cf211c68b5739afa2c67ba856739dccf1f /include/clientprotocol.h | |
parent | 45eff275cbc942a9b16f55367e6d5bd2bbfad2e0 (diff) |
Add an event provider class for the event/messagetag event.
Diffstat (limited to 'include/clientprotocol.h')
-rw-r--r-- | include/clientprotocol.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/include/clientprotocol.h b/include/clientprotocol.h index 95683dc8f..6ecfbc709 100644 --- a/include/clientprotocol.h +++ b/include/clientprotocol.h @@ -515,6 +515,16 @@ class ClientProtocol::Event void GetMessagesForUser(LocalUser* user, MessageList& messagelist); }; +class ClientProtocol::MessageTagEvent + : public Events::ModuleEventProvider +{ + public: + MessageTagEvent(Module* mod) + : ModuleEventProvider(mod, "event/messagetag") + { + } +}; + /** Base class for message tag providers. * All message tags belong to a message tag provider. Message tag providers can populate messages * with tags before the message is sent and they have the job of determining whether a user should @@ -667,7 +677,8 @@ struct ClientProtocol::RFCEvents */ class CoreExport ClientProtocol::Serializer : public DataProvider { - Events::ModuleEventProvider evprov; + private: + ClientProtocol::MessageTagEvent evprov; /** Make a white list containing which tags a user should get. * @param user User in question. |