?? unit2.~cpp
字號:
//---------------------------------------------------------------------
#include <vcl.h>
#pragma hdrstop
#include "Unit2.h"
//---------------------------------------------------------------------
#pragma resource "*.dfm"
TOKBottomDlg *OKBottomDlg;
//---------------------------------------------------------------------
__fastcall TOKBottomDlg::TOKBottomDlg(TComponent* AOwner)
: TForm(AOwner)
{
}
//---------------------------------------------------------------------
__fastcall TOKBottomDlg::TOKBottomDlg(int m_iArea, int m_iLevel, BOOL m_bMusic, BOOL m_bDrawGrid, TComponent* AOwner)
: TForm(AOwner)
{
m_oldArea = m_iArea;
m_oldLevel = m_iLevel;
m_oldMusic = m_bMusic;
m_oldDrawGrid = m_bDrawGrid;
m_bMusic = FALSE;
m_bDrawGrid = FALSE;
switch(m_iArea)
{
case 0:
ComboBox1->Text = "12行10列"; break;
case 1:
ComboBox1->Text = "18行15列"; break;
case 2:
ComboBox1->Text = "24行20列"; break;
case 3:
ComboBox1->Text = "30行25列"; break;
}
switch(m_iLevel)
{
case 0:
ComboBox2->Text = "第一級: 蝸牛級"; break;
case 1:
ComboBox2->Text = "第二級: 笨鴨級"; break;
case 2:
ComboBox2->Text = "第三級: 雄雞級"; break;
case 3:
ComboBox2->Text = "第四級: 獵狗級"; break;
case 4:
ComboBox2->Text = "第五級: 云豹級"; break;
case 5:
ComboBox2->Text = "第六級: 飛鷹級"; break;
}
}
void __fastcall TOKBottomDlg::OKBtnClick(TObject *Sender)
{
m_iArea = ComboBox1->ItemIndex;
if (m_iArea<0 || m_iArea>3)
m_iArea = 0;
m_iLevel = ComboBox2->ItemIndex;
if (m_iLevel<0 || m_iLevel>5)
m_iLevel = 2;
m_bMusic = CheckBox2->Checked;
m_bDrawGrid = CheckBox1->Checked;
}
//---------------------------------------------------------------------------
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -