-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathJoinDialog.cpp
More file actions
71 lines (54 loc) · 1.41 KB
/
JoinDialog.cpp
File metadata and controls
71 lines (54 loc) · 1.41 KB
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
// JoinDialog.cpp : implementation file
//
#include "stdafx.h"
#include "OpenGL.h"
#include "JoinDialog.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CJoinDialog dialog
CJoinDialog::CJoinDialog(CWnd* pParent /*=NULL*/)
: CDialog(CJoinDialog::IDD, pParent)
{
//{{AFX_DATA_INIT(CJoinDialog)
m_ipAdd = _T("");
//}}AFX_DATA_INIT
}
void CJoinDialog::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CJoinDialog)
DDX_Text(pDX, ID_IPADD, m_ipAdd);
DDV_MaxChars(pDX, m_ipAdd, 64);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CJoinDialog, CDialog)
//{{AFX_MSG_MAP(CJoinDialog)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CJoinDialog message handlers
void CJoinDialog::OnOK()
{
// TODO: Add extra validation here
CDialog::OnOK();
UpdateData(TRUE);
}
void CJoinDialog::OnCancel()
{
// TODO: Add extra cleanup here
CDialog::OnCancel();
}
BOOL CJoinDialog::OnInitDialog()
{
CDialog::OnInitDialog();
UpdateData(FALSE);
CEdit* pEditField = (CEdit *) (GetDlgItem(ID_IPADD));
pEditField->SetFocus();
// TODO: Add extra initialization here
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}