From 4df25d55cb0191414ae862b4196b1f4bf6de794e Mon Sep 17 00:00:00 2001 From: prozacx Date: Sun, 10 Jul 2005 23:50:37 +0000 Subject: [PATCH] Added InConfig() to tell whether this chan is saved in the config or not git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@426 726aef4b-f618-498e-8847-2d620e286838 --- Chan.cpp | 3 ++- Chan.h | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Chan.cpp b/Chan.cpp index 0e45a87f..c83566c9 100644 --- a/Chan.cpp +++ b/Chan.cpp @@ -4,7 +4,7 @@ #include "Utils.h" #include "IRCSock.h" -CChan::CChan(const CString& sName, CUser* pUser) { +CChan::CChan(const CString& sName, CUser* pUser, bool bInConfig) { m_sName = sName.Token(0); m_sKey = sName.Token(1); @@ -12,6 +12,7 @@ CChan::CChan(const CString& sName, CUser* pUser) { m_sName = "#" + m_sName; } + m_bInConfig = bInConfig; m_pUser = pUser; m_Nick.SetUser(pUser); m_bAutoCycle = m_pUser->AutoCycle(); diff --git a/Chan.h b/Chan.h index 439e8d49..d48c15e0 100644 --- a/Chan.h +++ b/Chan.h @@ -40,7 +40,7 @@ public: M_Except = 'e', } EModes; - CChan(const CString& sName, CUser* pUser); + CChan(const CString& sName, CUser* pUser, bool bInConfig); virtual ~CChan(); void Reset(); @@ -102,6 +102,7 @@ public: void SetAutoCycle(bool b) { m_bAutoCycle = b; } void SetWhoDone(bool b = true) { m_bWhoDone = b; } void SetDetached(bool b = true) { m_bDetached = b; } + void SetInConfig(bool b) { m_bInConfig = b; } // !Setters // Getters @@ -125,6 +126,7 @@ public: bool KeepBuffer() const { return m_bKeepBuffer; } bool AutoCycle() const { return m_bAutoCycle; } bool IsDetached() const { return m_bDetached; } + bool InConfig() const { return m_bInConfig; } // !Getters private: protected: @@ -133,6 +135,7 @@ protected: bool m_bWhoDone; bool m_bKeepBuffer; bool m_bAutoCycle; + bool m_bInConfig; CString m_sName; CString m_sKey; CString m_sCurKey;