Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members

CChatFrame Class Reference

#include <CtrlChatFrame.h>

Inheritance diagram for CChatFrame:

CPrivateChatFrame List of all members.

Public Member Functions

 CChatFrame ()
virtual ~CChatFrame ()
void SetDesktopMode (BOOL bDesktop)
virtual void OnSkinChange ()
virtual void OnStatusMessage (int nFlags, LPCTSTR pszText)
virtual void OnLocalText (LPCTSTR pszText)
virtual void OnLocalMessage (BOOL bAction, LPCTSTR pszText)
virtual void OnLocalCommand (LPCTSTR pszText, LPCTSTR pszCommand)
virtual BOOL PreTranslateMessage (MSG *pMsg)

Public Attributes

CChatSession * m_pSession

Protected Member Functions

void SetAlert (BOOL bAlert=TRUE)
void MoveHistory (int nDelta)
BOOL IsInRange (LPCTSTR pszToken)
void InsertText (LPCTSTR pszToken)
void AddText (LPCTSTR pszText)
void AddText (BOOL bSelf, BOOL bAction, LPCTSTR pszNick, LPCTSTR pszBody)
afx_msg int OnCreate (LPCREATESTRUCT lpCreateStruct)
afx_msg void OnDestroy ()
afx_msg void OnUpdateChatBold (CCmdUI *pCmdUI)
afx_msg void OnChatBold ()
afx_msg void OnUpdateChatItalic (CCmdUI *pCmdUI)
afx_msg void OnChatItalic ()
afx_msg void OnUpdateChatUnderline (CCmdUI *pCmdUI)
afx_msg void OnChatUnderline ()
afx_msg void OnChatColour ()
afx_msg void OnUpdateChatConnect (CCmdUI *pCmdUI)
afx_msg void OnChatConnect ()
afx_msg void OnUpdateChatDisconnect (CCmdUI *pCmdUI)
afx_msg void OnChatDisconnect ()
afx_msg void OnChatClear ()
afx_msg void OnChatEmoticons ()
afx_msg void OnMeasureItem (int nIDCtl, LPMEASUREITEMSTRUCT lpMeasureItemStruct)
afx_msg void OnDrawItem (int nIDCtl, LPDRAWITEMSTRUCT lpDrawItemStruct)
afx_msg void OnTimer (UINT nIDEvent)
afx_msg void OnSetFocus (CWnd *pOldWnd)
afx_msg void OnClickView (RVN_ELEMENTEVENT *pNotify, LRESULT *pResult)
afx_msg void OnUpdateChatTimestamp (CCmdUI *pCmdUI)
afx_msg void OnChatTimestamp ()

Protected Attributes

CRichDocument m_pContent
CRichViewCtrl m_wndView
CCoolBarCtrl m_wndToolBar
CEdit m_wndEdit
CMenu * m_pIconMenu
CStringArray m_pHistory
int m_nHistory
CString m_sCurrent
CChatWnd * m_pChildWnd
CWnd * m_pDesktopWnd

Constructor & Destructor Documentation

CChatFrame::CChatFrame (   ) 
 

Definition at line 78 of file CtrlChatFrame.cpp.

References NULL.

CChatFrame::~CChatFrame (   )  [virtual]
 

Definition at line 86 of file CtrlChatFrame.cpp.

References m_pSession, and NULL.


Member Function Documentation

void CChatFrame::AddText (  BOOL  bSelf,
BOOL  bAction,
LPCTSTR  pszNick,
LPCTSTR  pszBody
)  [protected]
 

Definition at line 352 of file CtrlChatFrame.cpp.

References CRichDocument::Add(), CSettings::Community, Emoticons, CEmoticons::FormatText(), CRichViewCtrl::InvalidateIfModified(), m_pContent, m_wndView, NEWLINE_FORMAT, NULL, retfBold, retfColour, retNewline, retText, Settings, and CSettings::sCommunity::Timestamp.

void CChatFrame::AddText (  LPCTSTR  pszText  )  [protected]
 

Definition at line 345 of file CtrlChatFrame.cpp.

References CRichDocument::Add(), CRichViewCtrl::InvalidateIfModified(), m_pContent, m_wndView, NEWLINE_FORMAT, retNewline, and retText.

Referenced by CPrivateChatFrame::OnLocalMessage(), CPrivateChatFrame::OnProfileReceived(), and CPrivateChatFrame::OnRemoteMessage().

void CChatFrame::InsertText (  LPCTSTR  pszToken  )  [protected]
 

Definition at line 320 of file CtrlChatFrame.cpp.

References m_wndEdit.

Referenced by OnChatBold(), OnChatColour(), OnChatEmoticons(), OnChatItalic(), and OnChatUnderline().

BOOL CChatFrame::IsInRange (  LPCTSTR  pszToken  )  [protected]
 

Definition at line 294 of file CtrlChatFrame.cpp.

References m_wndEdit.

Referenced by OnChatBold(), OnChatItalic(), OnChatUnderline(), OnUpdateChatBold(), OnUpdateChatItalic(), and OnUpdateChatUnderline().

void CChatFrame::MoveHistory (  int  nDelta  )  [protected]
 

Definition at line 271 of file CtrlChatFrame.cpp.

References m_nHistory, m_pHistory, m_sCurrent, and m_wndEdit.

Referenced by PreTranslateMessage().

void CChatFrame::OnChatBold (   )  [protected]
 

Definition at line 447 of file CtrlChatFrame.cpp.

References InsertText(), IsInRange(), and m_pSession.

Referenced by PreTranslateMessage().

void CChatFrame::OnChatClear (   )  [protected]
 

Definition at line 518 of file CtrlChatFrame.cpp.

References CRichDocument::Clear(), CRichViewCtrl::InvalidateIfModified(), m_pContent, and m_wndView.

void CChatFrame::OnChatColour (   )  [protected]
 

Definition at line 487 of file CtrlChatFrame.cpp.

References InsertText(), and m_pSession.

Referenced by PreTranslateMessage().

void CChatFrame::OnChatConnect (   )  [protected]
 

Definition at line 543 of file CtrlChatFrame.cpp.

References CChatSession::Connect(), CChatSession::GetConnectedState(), m_pSession, NULL, and TS_FALSE.

void CChatFrame::OnChatDisconnect (   )  [protected]
 

Definition at line 564 of file CtrlChatFrame.cpp.

References CChatSession::Close(), m_pSession, and NULL.

void CChatFrame::OnChatEmoticons (   )  [protected]
 

Definition at line 501 of file CtrlChatFrame.cpp.

References CEmoticons::CreateMenu(), Emoticons, CEmoticons::GetText(), ID_CHAT_EMOTICONS, InsertText(), m_pIconMenu, m_pSession, m_wndToolBar, NULL, and CCoolBarCtrl::ThrowMenu().

void CChatFrame::OnChatItalic (   )  [protected]
 

Definition at line 462 of file CtrlChatFrame.cpp.

References InsertText(), IsInRange(), and m_pSession.

Referenced by PreTranslateMessage().

void CChatFrame::OnChatTimestamp (   )  [protected]
 

Definition at line 529 of file CtrlChatFrame.cpp.

References CSettings::Community, Settings, and CSettings::sCommunity::Timestamp.

void CChatFrame::OnChatUnderline (   )  [protected]
 

Definition at line 477 of file CtrlChatFrame.cpp.

References InsertText(), IsInRange(), and m_pSession.

Referenced by PreTranslateMessage().

void CChatFrame::OnClickView (  RVN_ELEMENTEVENT *  pNotify,
LRESULT *  pResult
)  [protected]
 

Definition at line 641 of file CtrlChatFrame.cpp.

References CShareazaApp::InternalURI(), RVN_ELEMENTEVENT::pElement, and theApp.

int CChatFrame::OnCreate (  LPCREATESTRUCT  lpCreateStruct  )  [protected]
 

Reimplemented in CPrivateChatFrame.

Definition at line 94 of file CtrlChatFrame.cpp.

References CChatWindows::Add(), ChatWindows, CCoolBarCtrl::Create(), CRichViewCtrl::Create(), IDC_CHAT_EDIT, IDC_CHAT_TEXT, CShareazaApp::m_gdiFont, m_nHistory, m_pContent, m_wndEdit, m_wndToolBar, m_wndView, SetDesktopMode(), CRichViewCtrl::SetDocument(), CRichViewCtrl::SetFollowBottom(), CRichViewCtrl::SetSelectable(), and theApp.

Referenced by CPrivateChatFrame::OnCreate().

void CChatFrame::OnDestroy (   )  [protected]
 

Definition at line 123 of file CtrlChatFrame.cpp.

References ChatCore, ChatWindows, CChatCore::m_pSection, m_pSession, NULL, CChatSession::OnCloseWindow(), and CChatWindows::Remove().

void CChatFrame::OnDrawItem (  int  nIDCtl,
LPDRAWITEMSTRUCT  lpDrawItemStruct
)  [protected]
 

Definition at line 620 of file CtrlChatFrame.cpp.

References CoolInterface, CEmoticons::Draw(), Emoticons, CCoolInterface::m_crHighlight, and CCoolInterface::m_crWindow.

void CChatFrame::OnLocalCommand (  LPCTSTR  pszText,
LPCTSTR  pszCommand
)  [virtual]
 

Reimplemented in CPrivateChatFrame.

Definition at line 415 of file CtrlChatFrame.cpp.

References ID_CHAT_CLEAR, ID_CHAT_CONNECT, and ID_CHAT_DISCONNECT.

Referenced by CPrivateChatFrame::OnLocalCommand(), and OnLocalText().

void CChatFrame::OnLocalMessage (  BOOL  bAction,
LPCTSTR  pszText
)  [virtual]
 

Reimplemented in CPrivateChatFrame.

Definition at line 411 of file CtrlChatFrame.cpp.

Referenced by OnLocalText().

void CChatFrame::OnLocalText (  LPCTSTR  pszText  )  [virtual]
 

Definition at line 386 of file CtrlChatFrame.cpp.

References m_pSession, NULL, OnLocalCommand(), and OnLocalMessage().

Referenced by PreTranslateMessage().

void CChatFrame::OnMeasureItem (  int  nIDCtl,
LPMEASUREITEMSTRUCT  lpMeasureItemStruct
)  [protected]
 

Definition at line 614 of file CtrlChatFrame.cpp.

void CChatFrame::OnSetFocus (  CWnd *  pOldWnd  )  [protected]
 

Definition at line 608 of file CtrlChatFrame.cpp.

References m_wndEdit.

void CChatFrame::OnSkinChange (   )  [virtual]
 

Reimplemented in CPrivateChatFrame.

Definition at line 140 of file CtrlChatFrame.cpp.

Referenced by CChatWnd::OnSkinChange(), and CPrivateChatFrame::OnSkinChange().

void CChatFrame::OnStatusMessage (  int  nFlags,
LPCTSTR  pszText
)  [virtual]
 

Definition at line 378 of file CtrlChatFrame.cpp.

References CRichDocument::Add(), CRichViewCtrl::InvalidateIfModified(), m_pContent, m_wndView, NEWLINE_FORMAT, NULL, retfColour, retNewline, and retText.

Referenced by CChatWindows::OpenPrivate(), and CChatSession::StatusMessage().

void CChatFrame::OnTimer (  UINT  nIDEvent  )  [protected]
 

Definition at line 572 of file CtrlChatFrame.cpp.

References m_pChildWnd, NULL, and CChildWnd::SetAlert().

void CChatFrame::OnUpdateChatBold (  CCmdUI *  pCmdUI  )  [protected]
 

Definition at line 442 of file CtrlChatFrame.cpp.

References IsInRange().

void CChatFrame::OnUpdateChatConnect (  CCmdUI *  pCmdUI  )  [protected]
 

Definition at line 534 of file CtrlChatFrame.cpp.

References CCoolBarItem::FromCmdUI(), CChatSession::GetConnectedState(), CChatSession::m_nProtocol, m_pSession, NULL, PROTOCOL_ED2K, and TS_FALSE.

void CChatFrame::OnUpdateChatDisconnect (  CCmdUI *  pCmdUI  )  [protected]
 

Definition at line 555 of file CtrlChatFrame.cpp.

References CCoolBarItem::FromCmdUI(), CChatSession::GetConnectedState(), CChatSession::m_nProtocol, m_pSession, NULL, PROTOCOL_ED2K, and TS_FALSE.

void CChatFrame::OnUpdateChatItalic (  CCmdUI *  pCmdUI  )  [protected]
 

Definition at line 457 of file CtrlChatFrame.cpp.

References IsInRange().

void CChatFrame::OnUpdateChatTimestamp (  CCmdUI *  pCmdUI  )  [protected]
 

Definition at line 524 of file CtrlChatFrame.cpp.

References CSettings::Community, Settings, and CSettings::sCommunity::Timestamp.

void CChatFrame::OnUpdateChatUnderline (  CCmdUI *  pCmdUI  )  [protected]
 

Definition at line 472 of file CtrlChatFrame.cpp.

References IsInRange().

BOOL CChatFrame::PreTranslateMessage (  MSG *  pMsg  )  [virtual]
 

Definition at line 187 of file CtrlChatFrame.cpp.

References EDIT_HISTORY, m_nHistory, m_pHistory, m_pSession, m_sCurrent, m_wndEdit, m_wndView, MoveHistory(), NULL, OnChatBold(), OnChatColour(), OnChatItalic(), OnChatUnderline(), and OnLocalText().

void CChatFrame::SetAlert (  BOOL  bAlert = TRUE  )  [protected]
 

Definition at line 179 of file CtrlChatFrame.cpp.

Referenced by CPrivateChatFrame::OnProfileReceived(), and CPrivateChatFrame::OnRemoteMessage().

void CChatFrame::SetDesktopMode (  BOOL  bDesktop  ) 
 

Definition at line 147 of file CtrlChatFrame.cpp.

References m_pChildWnd, m_pDesktopWnd, CChatWnd::m_pFrame, and NULL.

Referenced by OnCreate().


Member Data Documentation

int CChatFrame::m_nHistory [protected]
 

Definition at line 55 of file CtrlChatFrame.h.

Referenced by MoveHistory(), OnCreate(), and PreTranslateMessage().

CChatWnd* CChatFrame::m_pChildWnd [protected]
 

Definition at line 58 of file CtrlChatFrame.h.

Referenced by OnTimer(), and SetDesktopMode().

CRichDocument CChatFrame::m_pContent [protected]
 

Definition at line 48 of file CtrlChatFrame.h.

Referenced by AddText(), OnChatClear(), OnCreate(), CPrivateChatFrame::OnProfileReceived(), and OnStatusMessage().

CWnd* CChatFrame::m_pDesktopWnd [protected]
 

Definition at line 59 of file CtrlChatFrame.h.

Referenced by SetDesktopMode().

CStringArray CChatFrame::m_pHistory [protected]
 

Definition at line 54 of file CtrlChatFrame.h.

Referenced by MoveHistory(), and PreTranslateMessage().

CMenu* CChatFrame::m_pIconMenu [protected]
 

Definition at line 52 of file CtrlChatFrame.h.

Referenced by OnChatEmoticons().

CChatSession* CChatFrame::m_pSession
 

Definition at line 46 of file CtrlChatFrame.h.

Referenced by CPrivateChatFrame::Accept(), CChatWindows::FindED2KFrame(), CChatWindows::FindPrivate(), CPrivateChatFrame::Initiate(), OnChatBold(), CPrivateChatFrame::OnChatBrowse(), OnChatColour(), OnChatConnect(), OnChatDisconnect(), OnChatEmoticons(), OnChatItalic(), CPrivateChatFrame::OnChatPriority(), OnChatUnderline(), OnDestroy(), CPrivateChatFrame::OnLocalMessage(), OnLocalText(), CPrivateChatFrame::OnProfileReceived(), CPrivateChatFrame::OnUpdateChatBrowse(), OnUpdateChatConnect(), OnUpdateChatDisconnect(), CPrivateChatFrame::OnUpdateChatPriority(), PreTranslateMessage(), and ~CChatFrame().

CString CChatFrame::m_sCurrent [protected]
 

Definition at line 56 of file CtrlChatFrame.h.

Referenced by MoveHistory(), and PreTranslateMessage().

CEdit CChatFrame::m_wndEdit [protected]
 

Definition at line 51 of file CtrlChatFrame.h.

Referenced by InsertText(), IsInRange(), MoveHistory(), OnCreate(), OnSetFocus(), CPrivateChatFrame::OnSize(), and PreTranslateMessage().

CCoolBarCtrl CChatFrame::m_wndToolBar [protected]
 

Definition at line 50 of file CtrlChatFrame.h.

Referenced by OnChatEmoticons(), OnCreate(), CPrivateChatFrame::OnSize(), and CPrivateChatFrame::OnSkinChange().

CRichViewCtrl CChatFrame::m_wndView [protected]
 

Definition at line 49 of file CtrlChatFrame.h.

Referenced by AddText(), OnChatClear(), OnCreate(), CPrivateChatFrame::OnSize(), OnStatusMessage(), and PreTranslateMessage().


The documentation for this class was generated from the following files:
Generated on Thu Dec 15 10:40:04 2005 for Shareaza 2.2.1.0 by  doxygen 1.4.2