mysocket.cpp
来自「断点.zip 断点续传的示例.可实现局网内的断点续传 源代码」· C++ 代码 · 共 48 行
CPP
48 行
// mysocket.cpp: implementation of the mysocket class.
//
//////////////////////////////////////////////////////////////////////
//*************************************************************
//作者:赵明
//EMAIL:zmpapaya@hotmail.com;papaya_zm@sina.com
//主页:http://h2osky.126.com
/********************************************************/
#include "stdafx.h"
#include "client1.h"
#include "mysocket.h"
#include "client1View.h"
#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif
//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////
mysocket::mysocket(CClient1View* view2)
{
view=view2;
}
mysocket::~mysocket()
{
}
void mysocket::OnReceive(int nErrorCode)
{
this->Receive(&m_buf,255);
CString aaa;
aaa.Format("%s",m_buf);
//AfxMessageBox(aaa);
view->Message((LPCTSTR)aaa,RGB(255,0,0));
//this->getpa
}
void mysocket::OnSend(int nErrorCode)
{
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?