-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathMessageDialog.cpp
More file actions
43 lines (34 loc) · 838 Bytes
/
MessageDialog.cpp
File metadata and controls
43 lines (34 loc) · 838 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#include "stdafx.h"
#include "cdm.h"
#include "MessageDialog.h"
#include "./messagedialog.h"
IMPLEMENT_DYNAMIC(CMessageDialog, CDialog)
CMessageDialog::CMessageDialog(CWnd* pParent /*=NULL*/)
: CDialog(IDD, pParent)
, m_Message(_T(""))
, m_Title(_T(""))
{
}
CMessageDialog::~CMessageDialog()
{
}
void CMessageDialog::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
DDX_Text(pDX, IDC_MESSAGE, m_Message);
}
BEGIN_MESSAGE_MAP(CMessageDialog, CDialog)
END_MESSAGE_MAP()
void CMessageDialog::MessageBox(LPCTSTR Title, LPCTSTR Message)
{
m_Title = Title;
m_Message = Message;
DoModal();
}
BOOL CMessageDialog::OnInitDialog()
{
CDialog::OnInitDialog();
SetWindowText(m_Title);
UpdateData(FALSE);
return TRUE; // return TRUE unless you set the focus to a control
}