ApplicationDlg.h 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119
  1. // ApplicationDlg.h : header file
  2. //
  3. #if !defined(AFX_APPLICATIONDLG_H__D3E3BA87_EEFA_11D5_AB1C_00D0B70C3D79__INCLUDED_)
  4. #define AFX_APPLICATIONDLG_H__D3E3BA87_EEFA_11D5_AB1C_00D0B70C3D79__INCLUDED_
  5. #if _MSC_VER > 1000
  6. #pragma once
  7. #endif // _MSC_VER > 1000
  8. #include "TracePage.h"
  9. #include "OnlineUsersPage.h"
  10. #include "ConfigurationPage.h"
  11. #include "StatisticsPage.h"
  12. #include "SecurityPage.h"
  13. #include "DialogResize.h"
  14. #include "FTPEventSink.h"
  15. #include "InfobarCtrl.h"
  16. class CApplicationDlg : public CDialogResize, CFTPEventSink
  17. {
  18. // Construction
  19. public:
  20. CApplicationDlg(CWnd* pParent = NULL); // standard constructor
  21. virtual ~CApplicationDlg();
  22. CTracePage m_TracePage;
  23. COnlineUsersPage m_OnlineUsersPage;
  24. CConfigurationPage m_ConfigurationPage;
  25. CStatisticsPage m_StatisticsPage;
  26. CSecurityPage m_SecurityPage;
  27. // Dialog Data
  28. //{{AFX_DATA(CApplicationDlg)
  29. enum { IDD = IDD_APPLICATION };
  30. CInfobarCtrl m_InfobarCtrl;
  31. CListCtrl m_OutlookBar;
  32. //}}AFX_DATA
  33. // ClassWizard generated virtual function overrides
  34. //{{AFX_VIRTUAL(CApplicationDlg)
  35. public:
  36. virtual BOOL PreTranslateMessage(MSG* pMsg);
  37. protected:
  38. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  39. //}}AFX_VIRTUAL
  40. // Implementation
  41. protected:
  42. char* FormatSize(DWORD dwSizeLow, DWORD dwSizeHigh);
  43. void SetOnlineLed(BOOL bOnline);
  44. void SetOfflineLed(BOOL bOffline);
  45. BOOL m_bInitialized;
  46. HICON m_hIcon;
  47. void SetupOutlookBar();
  48. CImageList m_ImageList;
  49. CToolTipCtrl m_ToolTipCtrl;
  50. void MoveChilds();
  51. void ActivatePage(int nIndex);
  52. BOOL CreateStatusbar();
  53. CStatusBar m_wndStatusBar;
  54. CToolBar m_wndToolBar;
  55. // Generated message map functions
  56. //{{AFX_MSG(CApplicationDlg)
  57. virtual BOOL OnInitDialog();
  58. afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
  59. afx_msg void OnSize(UINT nType, int cx, int cy);
  60. afx_msg void OnDestroy();
  61. afx_msg void OnServerStart();
  62. afx_msg void OnUpdateServerStart(CCmdUI* pCmdUI);
  63. afx_msg void OnServerStop();
  64. afx_msg void OnUpdateServerStop(CCmdUI* pCmdUI);
  65. afx_msg void OnServerExit();
  66. afx_msg void OnClickOutlookBar(NMHDR* pNMHDR, LRESULT* pResult);
  67. afx_msg void OnKeydownOutlookBar(NMHDR* pNMHDR, LRESULT* pResult);
  68. afx_msg void OnUserAccounts();
  69. afx_msg void OnClose();
  70. afx_msg void OnViewTrace();
  71. afx_msg void OnViewOnlineUsers();
  72. afx_msg void OnViewConfiguration();
  73. afx_msg void OnUpdateViewTrace(CCmdUI* pCmdUI);
  74. afx_msg void OnUpdateViewOnlineUsers(CCmdUI* pCmdUI);
  75. afx_msg void OnUpdateViewConfiguration(CCmdUI* pCmdUI);
  76. afx_msg void OnHelpAbout();
  77. afx_msg void OnApply();
  78. afx_msg void OnViewStatistics();
  79. afx_msg void OnUpdateViewStatistics(CCmdUI* pCmdUI);
  80. afx_msg void OnViewSecurity();
  81. afx_msg void OnUpdateViewSecurity(CCmdUI* pCmdUI);
  82. afx_msg void OnAccountWizard();
  83. virtual void OnCancel();
  84. virtual void OnOK();
  85. afx_msg void OnTimer(UINT nIDEvent);
  86. //}}AFX_MSG
  87. LRESULT OnKickIdle(WPARAM wParam, LPARAM lParam);
  88. LRESULT OnFtpStatistic(WPARAM wParam, LPARAM lParam);
  89. BOOL OnToolTipText(UINT, NMHDR* pNMHDR, LRESULT* pResult);
  90. DECLARE_MESSAGE_MAP()
  91. DECLARE_DLGRESIZE_MAP;
  92. virtual void OnFTPUserConnected(DWORD nThreadID, LPCTSTR lpszUser, LPCSTR lpszAddress);
  93. virtual void OnFTPUserDisconnected(DWORD nThreadID, LPCTSTR lpszUser);
  94. virtual void OnFTPStatusChange(int nType, LPCTSTR lpszText);
  95. virtual void OnFTPReceivedBytesChange(int nBytes);
  96. virtual void OnFTPSentBytesChange(int nBytes);
  97. virtual void OnFTPStatisticChange(int nType, int nValue);
  98. };
  99. //{{AFX_INSERT_LOCATION}}
  100. // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
  101. #endif // !defined(AFX_APPLICATIONDLG_H__D3E3BA87_EEFA_11D5_AB1C_00D0B70C3D79__INCLUDED_)