mirror of
https://github.com/znc/znc.git
synced 2026-08-07 17:33:34 +02:00
Allow reseting channel specific AutoClearChanBuffer & Buffer settings
The trick is to set the value to "-" in controlpanel. Notice that controlpanel supports wildcards, so this can be used to easily reset all channels back to defaults if desired.
This commit is contained in:
@@ -262,6 +262,11 @@ void CChan::InheritAutoClearChanBuffer(bool b) {
|
||||
}
|
||||
}
|
||||
|
||||
void CChan::ResetAutoClearChanBuffer() {
|
||||
SetAutoClearChanBuffer(m_pNetwork->GetUser()->AutoClearChanBuffer());
|
||||
m_bHasAutoClearChanBufferSet = false;
|
||||
}
|
||||
|
||||
void CChan::OnWho(const CString& sNick, const CString& sIdent, const CString& sHost) {
|
||||
CNick* pNick = FindNick(sNick);
|
||||
|
||||
@@ -656,3 +661,8 @@ void CChan::SetInConfig(bool b) {
|
||||
CZNC::Get().SetConfigState(CZNC::ECONFIG_NEED_WRITE);
|
||||
}
|
||||
}
|
||||
|
||||
void CChan::ResetBufferCount() {
|
||||
SetBufferCount(m_pNetwork->GetUser()->GetBufferCount());
|
||||
m_bHasBufferCountSet = false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user