⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 timelimit.cpp

📁 这是一字棋的极小极大搜索
💻 CPP
字号:
// timelimit.cpp : implementation file
//

#include "stdafx.h"
#include "ticktacktoe.h"
#include "ticktacktoeDoc.h"
#include "ticktacktoeView.h"
#include "MainFrm.h"
#include "timelimit.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CTimeLimit dialog
CTimeLimit::CTimeLimit(CWnd* pParent /*=NULL*/)
	: CDialog(CTimeLimit::IDD, pParent)
{
	//{{AFX_DATA_INIT(CTimeLimit)
		// NOTE: the ClassWizard will add member initialization here
	//}}AFX_DATA_INIT
}

void CTimeLimit::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(CTimeLimit)
		// NOTE: the ClassWizard will add DDX and DDV calls here
	//}}AFX_DATA_MAP
}

BEGIN_MESSAGE_MAP(CTimeLimit, CDialog)
	//{{AFX_MSG_MAP(CTimeLimit)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CTimeLimit message handlers

void CTimeLimit::OnOK() 
{
	// TODO: Add extra validation here
	CMainFrame *pFrame=(CMainFrame*)AfxGetApp()->m_pMainWnd;
	CTicktacktoeView *pView=(CTicktacktoeView *)(pFrame->GetActiveView());
	pView->timeLimits=20;
	this->MessageBox((char *)this->GetWindowText("",10));

	CDialog::OnOK();
}

void CTimeLimit::OnCancel() 
{
	// TODO: Add extra cleanup here
	
	CDialog::OnCancel();
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -