// DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
// Generated message map functions
//{{AFX_MSG(CProgressDialog)
virtual BOOL OnInitDialog();
virtual void OnCancel();
virtual void OnOK();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
class CMyProgressDialog:public CProgressDialog {
public:
CMyProgressDialog(LPCSTR caption):CProgressDialog(caption) {}
virtual DWORD ProgressProc(); //继承过程
};
// ProgressDialog.cpp
#include "stdafx.h"
#include "ProgressTest.h"
#include "ProgressDialog.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
CProgressDialog::CProgressDialog(LPCSTR caption, BOOL enableCancel, CWnd* pParent /*=NULL*/) :
CDialog(CProgressDialog::IDD, pParent)
{
//{{AFX_DATA_INIT(CProgressDialog)
m_Caption=caption;
m_EnableCancel=enableCancel;
m_IsCancel=FALSE;
m_Thread=NULL;
//}}AFX_DATA_INIT
}
CProgressDialog::~CProgressDialog(void)
{
if (m_Thread) {
CloseHandle(m_Thread);
}
}  
说明:本教程来源互联网或网友上传或出版商,仅为学习研究或媒体推广,wanshiok.com不保证资料的完整性。
2/2 首页 上一页 1 2 |