summaryrefslogtreecommitdiff
path: root/TAO/utils/NamingViewer/BindNewContext.cpp
blob: a846fa6cf3cd1f5304677c36e63b13ad3ac54bb7 (plain)
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
// $Id$
// BindNewContext.cpp : implementation file

#include "stdafx.h"
#include "NamingViewer.h"
#include "BindNewContext.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CBindNewContext dialog


CBindNewContext::CBindNewContext(CWnd* pParent /*=NULL*/)
	: CDialog(CBindNewContext::IDD, pParent)
{
	//{{AFX_DATA_INIT(CBindNewContext)
	m_ID = _T("");
	m_Kind = _T("");
	//}}AFX_DATA_INIT
}


void CBindNewContext::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(CBindNewContext)
	DDX_Text(pDX, IDC_ID, m_ID);
	DDX_Text(pDX, IDC_KIND, m_Kind);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(CBindNewContext, CDialog)
	//{{AFX_MSG_MAP(CBindNewContext)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CBindNewContext message handlers

void CBindNewContext::OnOK()
{
	// TODO: Add extra validation here
	UpdateData();
  m_Name.length(1);
  m_Name[0].id = CORBA::string_dup(ACE_TEXT_ALWAYS_CHAR (m_ID));
  m_Name[0].kind = CORBA::string_dup(ACE_TEXT_ALWAYS_CHAR (m_Kind));
	CDialog::OnOK();
}