資源簡介
圖形化實現:多線程并發同步,緩沖區容量為2,爸爸放蘋果,媽媽放橘子,兒子吃蘋果,女兒吃橘子。

代碼片段和文件信息
//?CZ_TASK2.cpp?:?Defines?the?class?behaviors?for?the?application.
//
#include?“stdafx.h“
#include?“CZ_TASK2.h“
#include?“CZ_TASK2Dlg.h“
#ifdef?_DEBUG
#define?new?DEBUG_NEW
#undef?THIS_FILE
static?char?THIS_FILE[]?=?__FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
//?CCZ_TASK2App
BEGIN_MESSAGE_MAP(CCZ_TASK2App?CWinApp)
//{{AFX_MSG_MAP(CCZ_TASK2App)
//?NOTE?-?the?ClassWizard?will?add?and?remove?mapping?macros?here.
//????DO?NOT?EDIT?what?you?see?in?these?blocks?of?generated?code!
//}}AFX_MSG
ON_COMMAND(ID_HELP?CWinApp::onhelp)
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
//?CCZ_TASK2App?construction
CCZ_TASK2App::CCZ_TASK2App()
{
//?TODO:?add?construction?code?here
//?Place?all?significant?initialization?in?InitInstance
}
/////////////////////////////////////////////////////////////////////////////
//?The?one?and?only?CCZ_TASK2App?object
CCZ_TASK2App?theApp;
/////////////////////////////////////////////////////////////////////////////
//?CCZ_TASK2App?initialization
BOOL?CCZ_TASK2App::InitInstance()
{
AfxEnableControlContainer();
//?Standard?initialization
//?If?you?are?not?using?these?features?and?wish?to?reduce?the?size
//??of?your?final?executable?you?should?remove?from?the?following
//??the?specific?initialization?routines?you?do?not?need.
#ifdef?_AFXDLL
Enable3dControls(); //?Call?this?when?using?MFC?in?a?shared?DLL
#else
Enable3dControlsStatic(); //?Call?this?when?linking?to?MFC?statically
#endif
CCZ_TASK2Dlg?dlg;
m_pMainWnd?=?&dlg;
int?nResponse?=?dlg.DoModal();
if?(nResponse?==?IDOK)
{
//?TODO:?Place?code?here?to?handle?when?the?dialog?is
//??dismissed?with?OK
}
else?if?(nResponse?==?IDCANCEL)
{
//?TODO:?Place?code?here?to?handle?when?the?dialog?is
//??dismissed?with?Cancel
}
//?Since?the?dialog?has?been?closed?return?FALSE?so?that?we?exit?the
//??application?rather?than?start?the?application‘s?message?pump.
return?FALSE;
}
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2013-11-14?22:09??ooooo\
?????文件???????48188??2013-11-14?08:10??ooooo\CZ_TASK2.APS
?????文件????????1234??2013-11-13?20:39??ooooo\CZ_TASK2.clw
?????文件????????2091??2010-10-18?16:15??ooooo\CZ_TASK2.cpp
?????文件????????4664??2013-11-13?21:24??ooooo\CZ_TASK2.dsp
?????文件?????????522??2010-10-18?16:15??ooooo\CZ_TASK2.dsw
?????文件????????1346??2010-10-18?16:15??ooooo\CZ_TASK2.h
?????文件???????91136??2013-11-14?08:19??ooooo\CZ_TASK2.ncb
?????文件???????53760??2013-11-14?08:19??ooooo\CZ_TASK2.opt
?????文件?????????977??2013-11-14?08:16??ooooo\CZ_TASK2.plg
?????文件????????6152??2013-11-14?08:10??ooooo\CZ_TASK2.rc
?????文件?????????880??2010-10-18?16:15??ooooo\CZ_TASK2.sln
?????文件????????7168??2010-10-18?16:15??ooooo\CZ_TASK2.suo
?????文件????????7724??2010-10-18?16:15??ooooo\CZ_TASK2.vcproj
?????文件????????1427??2010-10-18?16:15??ooooo\CZ_TASK2.vcproj.PC-20080611SWDO.Administrator.user
?????文件???????10865??2013-11-14?08:19??ooooo\CZ_TASK2Dlg.cpp
?????文件????????3461??2010-10-18?16:19??ooooo\CZ_TASK2Dlg.dsp
?????文件?????????528??2010-10-18?16:19??ooooo\CZ_TASK2Dlg.dsw
?????文件????????1896??2010-10-18?16:15??ooooo\CZ_TASK2Dlg.h
?????文件????10112000??2010-10-18?16:20??ooooo\CZ_TASK2Dlg.ncb
?????文件???????48640??2010-10-18?16:19??ooooo\CZ_TASK2Dlg.opt
?????文件?????????944??2010-10-18?16:19??ooooo\CZ_TASK2Dlg.plg
?????目錄???????????0??2013-11-14?22:09??ooooo\Debug\
?????文件??????122966??2013-11-14?08:16??ooooo\Debug\CZ_TASK2.exe
?????文件??????223440??2013-11-14?08:16??ooooo\Debug\CZ_TASK2.ilk
?????文件???????24862??2013-11-13?20:36??ooooo\Debug\CZ_TASK2.obj
?????文件?????5106216??2013-11-14?08:16??ooooo\Debug\CZ_TASK2.pch
?????文件??????394240??2013-11-14?08:16??ooooo\Debug\CZ_TASK2.pdb
?????文件???????11720??2013-11-14?08:11??ooooo\Debug\CZ_TASK2.res
?????文件???????53775??2013-11-14?08:16??ooooo\Debug\CZ_TASK2Dlg.obj
?????文件??????105896??2010-10-18?16:15??ooooo\Debug\StdAfx.obj
............此處省略16個文件信息
- 上一篇:stm32+mpu6050+QMC5883L
- 下一篇:重慶大學軟件學院uml課件
評論
共有 條評論