mirror of
https://github.com/znc/znc.git
synced 2026-03-28 17:42:41 +01:00
Add OnPrivBufferStarting/Ending signals, similar to Chan buffers
Allows hooking into query buffer playback before and after all the lines of the query buffer are replayed. The EModRet return value has no effect at the moment, but may be used in the future to e.g. prevent playback. The Chan version of these signals use EModRet to skip emitting the status message, but not the whole playback.
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
#include <znc/FileUtils.h>
|
||||
#include <znc/Template.h>
|
||||
#include <znc/User.h>
|
||||
#include <znc/Query.h>
|
||||
#include <znc/IRCNetwork.h>
|
||||
#include <znc/WebModules.h>
|
||||
#include <znc/znc.h>
|
||||
@@ -725,6 +726,12 @@ CModule::EModRet CModule::OnChanBufferPlayLine(CChan& Chan, CClient& Client,
|
||||
CString& sLine) {
|
||||
return CONTINUE;
|
||||
}
|
||||
CModule::EModRet CModule::OnPrivBufferStarting(CQuery& Query, CClient& Client) {
|
||||
return CONTINUE;
|
||||
}
|
||||
CModule::EModRet CModule::OnPrivBufferEnding(CQuery& Query, CClient& Client) {
|
||||
return CONTINUE;
|
||||
}
|
||||
CModule::EModRet CModule::OnPrivBufferPlayLine(CClient& Client,
|
||||
CString& sLine) {
|
||||
return CONTINUE;
|
||||
@@ -1343,6 +1350,12 @@ bool CModules::OnChanBufferPlayLine(CChan& Chan, CClient& Client,
|
||||
CString& sLine) {
|
||||
MODHALTCHK(OnChanBufferPlayLine(Chan, Client, sLine));
|
||||
}
|
||||
bool CModules::OnPrivBufferStarting(CQuery& Query, CClient& Client) {
|
||||
MODHALTCHK(OnPrivBufferStarting(Query, Client));
|
||||
}
|
||||
bool CModules::OnPrivBufferEnding(CQuery& Query, CClient& Client) {
|
||||
MODHALTCHK(OnPrivBufferEnding(Query, Client));
|
||||
}
|
||||
bool CModules::OnPrivBufferPlayLine2(CClient& Client, CString& sLine,
|
||||
const timeval& tv) {
|
||||
MODHALTCHK(OnPrivBufferPlayLine2(Client, sLine, tv));
|
||||
|
||||
Reference in New Issue
Block a user