📄 modeselect.cpp
字号:
// ModeSelect.cpp : implementation file
//
#include "stdafx.h"
#include "alfa.h"
#include "ModeSelect.h"
#include "Main.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CModeSelect dialog
CModeSelect::CModeSelect(CWnd* pParent /*=NULL*/)
: CDialog(CModeSelect::IDD, pParent)
{
//{{AFX_DATA_INIT(CModeSelect)
//}}AFX_DATA_INIT
}
void CModeSelect::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CModeSelect)
DDX_Control(pDX, IDC_RADIO2, m_radio2);
DDX_Control(pDX, IDC_RADIO1, m_radio1);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CModeSelect, CDialog)
//{{AFX_MSG_MAP(CModeSelect)
ON_BN_CLICKED(IDC_RADIO2, OnRadio2)
ON_BN_CLICKED(IDC_BUTTON1, OnButton1)
ON_BN_CLICKED(IDC_RADIO1, OnRadio1)
ON_BN_CLICKED(IDC_BUTTON2, OnButton2)
ON_WM_SHOWWINDOW()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CModeSelect message handlers
void CModeSelect::OnRadio2()
{
// TODO: Add your control notification handler code here
m_radio1.SetCheck(0);
m_radio2.SetCheck(1);
}
void CModeSelect::OnButton1()
{
// TODO: Add your control notification handler code here
CMain * main=(CMain *)GetParent();
if(m_radio2.GetCheck()==1)
{
ShowWindow(FALSE);
main->dlgfixedmode->ShowWindow(TRUE);
}
else
{
ShowWindow(FALSE);
main->dlgmodeteachsel->ShowWindow(TRUE);
}
}
void CModeSelect::OnRadio1()
{
// TODO: Add your control notification handler code here
m_radio1.SetCheck(1);
m_radio2.SetCheck(0);
}
BOOL CModeSelect::OnInitDialog()
{
CDialog::OnInitDialog();
h_SkinDialog.SubClassDialog(m_hWnd);
// TODO: Add extra initialization here
m_radio2.SetCheck(1);
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
void CModeSelect::OnButton2()
{
// TODO: Add your control notification handler code here
CMain * main=(CMain *)GetParent();
ShowWindow(FALSE);
main->dlgmainfrm->ShowWindow(TRUE);
}
void CModeSelect::OnShowWindow(BOOL bShow, UINT nStatus)
{
CDialog::OnShowWindow(bShow, nStatus);
// TODO: Add your message handler code here
if(bShow==1)
{
CMain * main=(CMain *)GetParent();
main->dlgcur=this;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -