📄 addsingerdlg.cpp
字号:
// AddSingerDlg.cpp : implementation file
//
#include "stdafx.h"
#include "YLmms.h"
#include "AddSingerDlg.h"
#include "MainFrm.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CAddSingerDlg dialog
CAddSingerDlg::CAddSingerDlg(CWnd* pParent /*=NULL*/)
: CDialog(CAddSingerDlg::IDD, pParent)
{
//{{AFX_DATA_INIT(CAddSingerDlg)
m_strsingername = _T("");
//}}AFX_DATA_INIT
}
void CAddSingerDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CAddSingerDlg)
DDX_Control(pDX, IDC_COMBO_CLASSIFY, m_comboclassify);
DDX_Control(pDX, IDC_COMBO_SEX, m_strcombosex);
DDX_Text(pDX, IDC_EDIT_DIR, m_strsingername);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CAddSingerDlg, CDialog)
//{{AFX_MSG_MAP(CAddSingerDlg)
ON_CBN_SELENDOK(IDC_COMBO_SEX, OnSelendokComboSex)
ON_CBN_SELENDOK(IDC_COMBO_CLASSIFY, OnSelendokComboClassify)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CAddSingerDlg message handlers
BOOL CAddSingerDlg::OnInitDialog()
{
CDialog::OnInitDialog();
// TODO: Add extra initialization here
m_comboclassify.AddString(_T("古典"));
m_comboclassify.AddString(_T("流行"));
m_comboclassify.AddString(_T("欧美金曲"));
m_comboclassify.AddString(_T("日韩"));
m_comboclassify.AddString(_T("中国民乐"));
m_comboclassify.AddString(_T("流金岁月"));
m_comboclassify.AddString(_T("轻音乐"));
m_comboclassify.AddString(_T("少儿"));
m_strcombosex.AddString(_T("男"));
m_strcombosex.AddString(_T("女"));
m_comboclassify.SetCurSel(0);
m_strcombosex.SetCurSel(1);
CMainFrame* pMainFrm=(CMainFrame*)AfxGetMainWnd();
m_strcombosex.GetLBText(m_strcombosex.GetCurSel(), pMainFrm->m_strsex);
m_comboclassify.GetLBText(m_comboclassify.GetCurSel(),pMainFrm->m_strClassify);
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
void CAddSingerDlg::OnSelendokComboSex()
{
// TODO: Add your control notification handler code here
// TODO: Add your control notification handler code here
CMainFrame* pMainFrm=(CMainFrame*)AfxGetMainWnd();
//获取歌手性别
m_strcombosex.GetLBText(m_strcombosex.GetCurSel(),
pMainFrm->m_strsex);
}
void CAddSingerDlg::OnSelendokComboClassify()
{
// TODO: Add your control notification handler code here
// TODO: Add your control notification handler code here
CMainFrame* pMainFrm=(CMainFrame*)AfxGetMainWnd();
//获取歌手性别
m_comboclassify.GetLBText(m_comboclassify.GetCurSel(),
pMainFrm->m_strClassify);
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -