Added support for buffering of /me actions

git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@602 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
prozacx
2006-02-01 07:45:54 +00:00
parent 9d8bb77de7
commit 2cd52ad39a
2 changed files with 18 additions and 8 deletions

View File

@@ -383,11 +383,20 @@ void CClient::ReadLine(const CString& sData) {
return;
}
CChan* pChan = m_pUser->FindChan(sTarget);
if (sCTCP.Token(0).CaseCmp("ACTION") == 0) {
if (pChan && pChan->KeepBuffer()) {
pChan->AddBuffer(":" + GetNickMask() + " PRIVMSG " + sTarget + " :\001" + sCTCP + "\001");
}
#ifdef _MODULES
CZNC::Get().GetModules().SetClient(this);
MODULECALLRET(OnUserCTCP(sTarget, sCTCP));
CZNC::Get().GetModules().SetClient(NULL);
} else {
CZNC::Get().GetModules().SetClient(this);
MODULECALLRET(OnUserCTCP(sTarget, sCTCP));
CZNC::Get().GetModules().SetClient(NULL);
#endif
}
PutIRC("PRIVMSG " + sTarget + " :\001" + sCTCP + "\001");
return;
}