DragonNest/Client/EtUITool/CustomControlSelect.cpp
Cussrro 47f7895977 Revert "修复编码问题"
This reverts commit 9e69c01767.
2024-12-21 10:04:04 +08:00

60 lines
1.2 KiB
C++

// CustomControlSelect.cpp : implementation file
//
#include "stdafx.h"
#include "EtUITool.h"
#include "CustomControlSelect.h"
#include "RenderBase.h"
extern std::vector< std::string > g_vecCustomControlName;
// CCustomControlSelect dialog
IMPLEMENT_DYNAMIC(CCustomControlSelect, CDialog)
CCustomControlSelect::CCustomControlSelect(CWnd* pParent /*=NULL*/)
: CDialog(CCustomControlSelect::IDD, pParent)
{
m_nCurSel = -1;
}
CCustomControlSelect::~CCustomControlSelect()
{
}
void CCustomControlSelect::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
DDX_Control(pDX, IDC_CUSTOM_COMBO, m_CustomSelect);
}
BEGIN_MESSAGE_MAP(CCustomControlSelect, CDialog)
ON_BN_CLICKED(IDOK, &CCustomControlSelect::OnBnClickedOk)
END_MESSAGE_MAP()
// CCustomControlSelect message handlers
BOOL CCustomControlSelect::OnInitDialog()
{
CDialog::OnInitDialog();
int i;
for( i = 0; i < ( int )g_vecCustomControlName.size(); i++ )
{
m_CustomSelect.InsertString( i, g_vecCustomControlName[i].c_str() );
}
m_CustomSelect.SetCurSel( 0 );
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
void CCustomControlSelect::OnBnClickedOk()
{
m_nCurSel = m_CustomSelect.GetCurSel();
OnOK();
}