📄 progressdlg.cpp
字号:
// ProgressDlg.cpp : implementation file
//
#include "stdafx.h"
#include "sf1553.h"
#include "ProgressDlg.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CProgressDlg dialog
BYTE pgbarOpt=0;
DWORD dwbarmax=0;
DWORD dwbarmin=0;
DWORD dwbarpos=0;
CProgressDlg::CProgressDlg(CWnd* pParent /*=NULL*/)
: CDialog(CProgressDlg::IDD, pParent)
{
//{{AFX_DATA_INIT(CProgressDlg)
// NOTE: the ClassWizard will add member initialization here
//}}AFX_DATA_INIT
}
void CProgressDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CProgressDlg)
DDX_Control(pDX, IDC_PD_BAR, m_pgBar);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CProgressDlg, CDialog)
//{{AFX_MSG_MAP(CProgressDlg)
ON_MESSAGE(CWM_PGB_DEXT, OnCMsgDExt)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CProgressDlg message handlers
BOOL CProgressDlg::OnInitDialog()
{
CDialog::OnInitDialog();
// TODO: Add extra initialization here
this->m_pgBar.SetRange32(dwbarmin, dwbarmax);
this->m_pgBar.SetPos(dwbarpos);
return TRUE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
void CProgressDlg::OnCMsgDExt()
{
if (pgbarOpt==0)
{
// update progress bar showing
//
this->m_pgBar.SetPos(dwbarpos);
}
else
{
// exit window
//
CDialog::OnClose();
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -