📄 chatsocket.cpp
字号:
// ChatSocket.cpp: implementation of the CChatSocket class.
//
//////////////////////////////////////////////////////////////////////
#include "stdafx.h"
#include "ChatClient.h"
#include "ChatSocket.h"
#include "ClientDlg.h"
#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif
//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////
IMPLEMENT_DYNAMIC(CChatSocket,CSocket)
//构造函数
CChatSocket::CChatSocket(CClientDlg* pDlg)
{
//成员变量赋值
m_pDlg=pDlg;
}
//事件处理函数
void CChatSocket::OnReceive(int nErrorCode)
{
CSocket::OnReceive(nErrorCode);
//调用CClientDlg类的相应函数处理
m_pDlg->OnReceive();
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -