SNCSetupDlg.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. // SNCSetupDlg.h : 头文件
  2. //
  3. #pragma once
  4. #include "afxwin.h"
  5. #include "global.h"
  6. #include "autoupdate.h"
  7. // CSNCSetupDlg 对话框
  8. class CSNCSetupDlg : public CDialog
  9. {
  10. // 构造
  11. public:
  12. CSNCSetupDlg(CWnd* pParent = NULL); // 标准构造函数
  13. // 对话框数据
  14. enum { IDD = IDD_SNCSETUP_DIALOG };
  15. CProgressCtrl m_progress;
  16. CStatic m_currentinfo;
  17. protected:
  18. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持
  19. void SetProgressToMarquee(int nID);
  20. void SetProgressNoMarquee();
  21. void SetNetworkNotAvailable();
  22. void SetNetworkAvailable();
  23. void SetDownloadError();
  24. void SetSetupAvailable();
  25. void SetSystemError(int errCode);
  26. void SetUserAbort();
  27. void SetVersionUpdated();
  28. void SetVersionNotNeedUpdate();
  29. void SetSetupFinished();
  30. // 实现
  31. protected:
  32. HICON m_hIcon;
  33. // 生成的消息映射函数
  34. virtual BOOL OnInitDialog();
  35. afx_msg void OnPaint();
  36. afx_msg void OnClose();
  37. afx_msg HCURSOR OnQueryDragIcon();
  38. afx_msg LRESULT onUserMsgUpgradeSate (WPARAM wParam, LPARAM lParam);
  39. afx_msg LRESULT onUserMsgUpgradeProgress (WPARAM wParam, LPARAM lParam);
  40. afx_msg LRESULT onUserMsgUpgradeChilidProgress (WPARAM wParam, LPARAM lParam);
  41. afx_msg LRESULT onUserMsgUpgradeRange (WPARAM wParam, LPARAM lParam);
  42. DECLARE_MESSAGE_MAP()
  43. public:
  44. afx_msg void OnBnClickedButtonClose();
  45. private:
  46. int m_step;
  47. int m_filecount;
  48. CAutoUpdate m_update;
  49. ThreadParamInfo m_threadParam;
  50. void StartUpdate();
  51. void DownloadFiles();
  52. void UpdateProgress();
  53. COleDateTime dlStart;
  54. COleDateTimeSpan dlElapsed;
  55. bool m_bStop;
  56. public:
  57. CButton m_buttonclose;
  58. bool confirm;
  59. bool deluserdata ;
  60. bool isproduct;
  61. };