www.pudn.com > agentnet.zip > ReceiveGeneralMsgDlg.cpp
// ReceiveGeneralMsgDlg.cpp : implementation file
//
#include "stdafx.h"
#include "AgentNetClient.h"
#include "ReceiveGeneralMsgDlg.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CReceiveGeneralMsgDlg dialog
CReceiveGeneralMsgDlg::CReceiveGeneralMsgDlg(CWnd* pParent /*=NULL*/)
: CDialog(CReceiveGeneralMsgDlg::IDD, pParent)
{
//{{AFX_DATA_INIT(CReceiveGeneralMsgDlg)
m_strText = _T("");
//}}AFX_DATA_INIT
}
void CReceiveGeneralMsgDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CReceiveGeneralMsgDlg)
DDX_Text(pDX, IDC_EDIT_MESSAEG, m_strText);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CReceiveGeneralMsgDlg, CDialog)
//{{AFX_MSG_MAP(CReceiveGeneralMsgDlg)
ON_WM_CREATE()
ON_BN_CLICKED(IDC_BUTTON_REPLY, OnButtonReply)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CReceiveGeneralMsgDlg message handlers
int CReceiveGeneralMsgDlg::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
if (CDialog::OnCreate(lpCreateStruct) == -1)
return -1;
// TODO: Add your specialized creation code here
//改变对话框标题为用户名
SetWindowText("收到来自 "+m_strFromUserName+" 的消息: ");
m_bReply=FALSE;
return 0;
}
void CReceiveGeneralMsgDlg::OnButtonReply()
{
// TODO: Add your control notification handler code here
m_bReply=TRUE;
OnOK();
}