-
Notifications
You must be signed in to change notification settings - Fork 1
/
DlgChooseNetName.cpp
52 lines (41 loc) · 1002 Bytes
/
DlgChooseNetName.cpp
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
// DlgChooseNetName.cpp : implementation file
//
#include "stdafx.h"
#include "FreePcb.h"
#include "DlgChooseNetName.h"
// CDlgChooseNetName dialog
IMPLEMENT_DYNAMIC(CDlgChooseNetName, CDialog)
CDlgChooseNetName::CDlgChooseNetName(CWnd* pParent /*=NULL*/)
: CDialog(CDlgChooseNetName::IDD, pParent)
{
}
CDlgChooseNetName::~CDlgChooseNetName()
{
}
void CDlgChooseNetName::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
DDX_Control(pDX, IDC_COMBO1, m_combo_names);
if( !pDX->m_bSaveAndValidate )
{
// incoming
for( int i=0; i<m_str->GetSize(); i++ )
{
CString s = (*m_str)[i];
m_combo_names.InsertString( i, s );
}
m_combo_names.SetCurSel( 0 );
}
else
{
// outgoing
m_combo_names.GetWindowText( m_sel_str );
}
}
void CDlgChooseNetName::Initialize( CArray<CString> * str )
{
m_str = str;
}
BEGIN_MESSAGE_MAP(CDlgChooseNetName, CDialog)
END_MESSAGE_MAP()
// CDlgChooseNetName message handlers