www.pudn.com > seedesk.zip > ListenlingSocket.cpp
// ListenlingSocket.cpp : implementation file
//
/***************************************************************************
* Module : *
*
* *
* Created by : ?? Date : 2004.9.12 *
* Modified by : Date : *
* *
* *
***************************************************************************/
#include "stdafx.h"
#include "EmployerSever.h"
#include "ListenlingSocket.h"
#include "EmployerSeverDlg.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CListenlingSocket
CListenlingSocket::CListenlingSocket(CEmployerSeverDlg* pDlg)
{
m_pDlg=pDlg;//指向创建对话框的指针
}
CListenlingSocket::~CListenlingSocket()
{
if(m_pDlg!=NULL)
{ delete m_pDlg;
m_pDlg=NULL;}
}
// Do not edit the following lines, which are needed by ClassWizard.
#if 0
BEGIN_MESSAGE_MAP(CListenlingSocket, CSocket)
//{{AFX_MSG_MAP(CListenlingSocket)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
#endif // 0
/////////////////////////////////////////////////////////////////////////////
// CListenlingSocket member functions
//发生接受事件教由dlg处理
void CListenlingSocket::OnAccept(int nErrorCode)
{
// TODO: Add your specialized code here and/or call the base class
CSocket::OnAccept(nErrorCode);
m_pDlg->Accept();
}