📄 dlgsetgame.cpp
字号:
// DlgSetGame.cpp : implementation file
//
#include "stdafx.h"
#include "linkgameex.h"
#include "DlgSetGame.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CDlgSetGame dialog
CDlgSetGame::CDlgSetGame(CWnd* pParent /*=NULL*/)
: CDialog(CDlgSetGame::IDD, pParent)
{
//{{AFX_DATA_INIT(CDlgSetGame)
// NOTE: the ClassWizard will add member initialization here
//}}AFX_DATA_INIT
}
void CDlgSetGame::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CDlgSetGame)
DDX_Control(pDX, IDC_TXTGAMECANSHU, m_txtGameCanShu);
DDX_Control(pDX, IDC_TXTGAMAPATH, m_txtGamePath);
DDX_Control(pDX, IDC_GAMETREE, m_GameTree);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CDlgSetGame, CDialog)
//{{AFX_MSG_MAP(CDlgSetGame)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CDlgSetGame message handlers
BOOL CDlgSetGame::OnInitDialog()
{
CDialog::OnInitDialog();
// TODO: Add extra initialization here
HTREEITEM m_hItem = this->m_GameTree.InsertItem( "单机游戏", TVI_ROOT); //在根结点上添加 "棋牌游戏"
int i = 1, j = 1;
while(1)
{
// 读取游戏名称
if( 0 == strlen(GetGameName( "DanJiYouXi", i)))
{
i = 1;
break;
}
else
{
HTREEITEM m_testhItem = this->m_GameTree.InsertItem( GetGameName( "DanJiYouXi", i), m_hItem);
while(1)
{
// 读取游戏房间名称
if( 0 == strlen(GetGameRoom( GetGameName( "DanJiYouXi", i), j)))
{
j = 1;
break;
}
else
{
this->m_GameTree.InsertItem( GetGameRoom( GetGameName( "DanJiYouXi", i), j), m_testhItem);
j++;
}
}
i++;
}
}
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -