Umasoft
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
ProgDlg.h
1 //
2 // ProgDlg.h : header file
3 // CG: This file was added by the Progress Dialog component
4 //
5 // Copyright (c) 2001 Virtual Terrain Project
6 // Free for all uses, see license.txt for details.
7 //
8 
10 // CProgressDlg dialog
11 
12 #ifndef __PROGDLG_H__
13 #define __PROGDLG_H__
14 
15 
16 class CProgressDlg : public CDialog
17 {
18 // Construction / Destruction
19 public:
20  CProgressDlg(UINT nCaptionID = 0); // standard constructor
21  ~CProgressDlg();
22 
23  BOOL Create(CWnd *pParent=NULL);
24 
25  // Progress Dialog manipulation
26  void SetStatus(LPCTSTR szMessage);
27  void SetRange(int nLower,int nUpper);
28  int SetStep(int nStep);
29  int SetPos(int nPos);
30  int OffsetPos(int nPos);
31  int StepIt();
32 
33 // Dialog Data
34  //{{AFX_DATA(CProgressDlg)
35  enum { IDD = CG_IDD_PROGRESS };
36  CProgressCtrl m_Progress;
37  //}}AFX_DATA
38 
39 // Overrides
40  // ClassWizard generated virtual function overrides
41  //{{AFX_VIRTUAL(CProgressDlg)
42  public:
43  virtual BOOL DestroyWindow();
44  protected:
45  virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
46  //}}AFX_VIRTUAL
47 
48 // Implementation
49 protected:
50  UINT m_nCaptionID;
51  int m_nLower;
52  int m_nUpper;
53  int m_nStep;
54  BOOL m_bParentDisabled;
55 
56  void ReEnableParent();
57 
58  virtual void OnCancel();
59  virtual void OnOK() {};
60  void PumpMessages();
61 
62  // Generated message map functions
63  //{{AFX_MSG(CProgressDlg)
64  virtual BOOL OnInitDialog();
65  //}}AFX_MSG
66  DECLARE_MESSAGE_MAP()
67 };
68 
69 #endif // __PROGDLG_H__