資源簡介
在MFC中實現的動畫播放 運行程序后 可以直接播放

代碼片段和文件信息
//?PlayFlash.cpp?:?Defines?the?class?behaviors?for?the?application.
//
#include?“stdafx.h“
#include?“PlayFlash.h“
#include?“PlayFlashDlg.h“
#ifdef?_DEBUG
#define?new?DEBUG_NEW
#undef?THIS_FILE
static?char?THIS_FILE[]?=?__FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
//?CPlayFlashApp
BEGIN_MESSAGE_MAP(CPlayFlashApp?CWinApp)
//{{AFX_MSG_MAP(CPlayFlashApp)
//?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()
/////////////////////////////////////////////////////////////////////////////
//?CPlayFlashApp?construction
CPlayFlashApp::CPlayFlashApp()
{
//?TODO:?add?construction?code?here
//?Place?all?significant?initialization?in?InitInstance
}
/////////////////////////////////////////////////////////////////////////////
//?The?one?and?only?CPlayFlashApp?object
CPlayFlashApp?theApp;
HINSTANCE?hInst;
typedef?int?(__stdcall?*?REGISTERFUNC)(void);
/////////////////////////////////////////////////////////////////////////////
//?CPlayFlashApp?initialization
BOOL?CPlayFlashApp::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
/*注冊shockwave?flash?object控件,控件不能放在有中文的路徑下
TCHAR?strCurDrt[500];
int?nLen?=?::GetCurrentDirectory(500strCurDrt);
if(?strCurDrt[nLen]!=‘\\‘?)
{
strCurDrt[nLen++]?=?‘\\‘;
strCurDrt[nLen]?=?‘\0‘;
}
CString?strFileName?=?strCurDrt;
strFileName?+=“flash.ocx“;
AfxMessageBox(strFileName);
hInst?=?NULL;
hInst?=?LoadLibrary(?strFileName?);
if(?!hInst?)
{
AfxMessageBox(“加載flash.ocx失敗,請檢查flash.ocx是否和程序在同一目錄下“);
}
else
{
REGISTERFUNC?pRegister;
pRegister?=?GetProcAddress((HMODULE)hInst“DllRegisterServer“?);
(*pRegister)();
}
*/
CPlayFlashDlg?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;
}
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件???????1133??2004-07-31?00:24??PlayFlash\PlayFlash.clw
?????文件???????2795??2004-07-31?00:24??PlayFlash\PlayFlash.cpp
?????文件???????4744??2004-07-31?00:14??PlayFlash\PlayFlash.dsp
?????文件????????587??2004-07-30?22:20??PlayFlash\PlayFlash.dsw
?????文件??????20480??2004-07-31?00:24??PlayFlash\PlayFlash.exe
?????文件???????1357??2004-07-30?21:52??PlayFlash\PlayFlash.h
?????文件??????49664??2004-07-31?00:25??PlayFlash\PlayFlash.opt
?????文件?????418816??2004-07-31?00:22??PlayFlash\PlayFlash.pdb
?????文件????????953??2004-07-31?00:24??PlayFlash\PlayFlash.plg
?????文件???????6321??2004-07-30?22:52??PlayFlash\PlayFlash.rc
?????文件???????5171??2004-07-31?00:21??PlayFlash\PlayFlashDlg.cpp
?????文件???????1520??2004-07-30?22:53??PlayFlash\PlayFlashDlg.h
?????文件???????3633??2004-07-30?21:52??PlayFlash\ReadMe.txt
?????文件???????1078??2004-07-30?21:52??PlayFlash\res\PlayFlash.ico
?????文件????????401??2004-07-30?21:52??PlayFlash\res\PlayFlash.rc2
????..A.SH.??????3072??2007-11-16?19:46??PlayFlash\res\Thumbs.db
?????文件????????687??2004-07-30?22:20??PlayFlash\Resource.h
?????文件??????14270??2004-07-30?22:03??PlayFlash\shockwaveflash.cpp
?????文件???????4367??2004-07-30?22:03??PlayFlash\shockwaveflash.h
?????文件?????147456??2004-07-31?00:13??PlayFlash\startup.fla
?????文件??????17167??2004-07-30?22:56??PlayFlash\startup.swf
?????文件????????211??2004-07-30?21:52??PlayFlash\StdAfx.cpp
?????文件???????1054??2004-07-30?21:52??PlayFlash\StdAfx.h
?????目錄??????????0??2007-11-16?20:35??PlayFlash\res
?????目錄??????????0??2009-09-02?13:34??PlayFlash
?????文件??????21388??2009-09-02?13:35??PlayFlash\PlayFlash\PlayFlash.aps
?????文件???????1133??2009-09-02?14:27??PlayFlash\PlayFlash\PlayFlash.clw
?????文件???????2795??2004-07-31?00:24??PlayFlash\PlayFlash\PlayFlash.cpp
?????文件???????4744??2004-07-31?00:14??PlayFlash\PlayFlash\PlayFlash.dsp
?????文件????????587??2004-07-30?22:20??PlayFlash\PlayFlash\PlayFlash.dsw
............此處省略32個文件信息
- 上一篇:VC++ 6.0 msdn中文版
- 下一篇:幾個c++游戲源代碼
評論
共有 條評論