Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

85 lines
2.3 KiB

  1. //+---------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1992 - 1995
  5. //
  6. // File: hostobj.h
  7. //
  8. // Contents: Contains the main application object
  9. //
  10. //----------------------------------------------------------------------------
  11. //****************************************************************************
  12. //
  13. // Classes
  14. //
  15. //****************************************************************************
  16. //+---------------------------------------------------------------------------
  17. //
  18. // Class: CConfig (cdd)
  19. //
  20. // Purpose: Class which runs the configuration dialog. We run it in a
  21. // separate thread because we cannot afford to block the main
  22. // thread on UI stuff.
  23. //
  24. //----------------------------------------------------------------------------
  25. class CConfig : public CThreadComm
  26. {
  27. friend BOOL CALLBACK
  28. ConfigDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam);
  29. public:
  30. DECLARE_STANDARD_IUNKNOWN(CConfig);
  31. CConfig(CMTScript *pMT) : _pMT(pMT) { _ulRefs = 1; }
  32. CMTScript * _pMT;
  33. protected:
  34. virtual DWORD ThreadMain();
  35. void InitializeConfigDialog(HWND hwnd);
  36. BOOL CommitConfigChanges(HWND hwnd);
  37. private:
  38. HWND _hwnd;
  39. };
  40. //+---------------------------------------------------------------------------
  41. //
  42. // Class: CMessageBoxTimeout (cdd)
  43. //
  44. // Purpose: Class which runs the configuration dialog. We run it in a
  45. // separate thread because we cannot afford to block the main
  46. // thread on UI stuff.
  47. //
  48. //----------------------------------------------------------------------------
  49. class CMessageBoxTimeout : public CThreadComm
  50. {
  51. friend BOOL CALLBACK
  52. MBTimeoutDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam);
  53. public:
  54. DECLARE_STANDARD_IUNKNOWN(CMessageBoxTimeout);
  55. CMessageBoxTimeout(MBTIMEOUT *pmbt) : _pmbt(pmbt) { _ulRefs = 1; }
  56. MBTIMEOUT *_pmbt;
  57. long _lSecondsTilCancel;
  58. long _lSecondsTilNextEvent;
  59. HWND _hwnd;
  60. protected:
  61. virtual DWORD ThreadMain();
  62. void InitializeDialog(HWND hwnd);
  63. void OnCommand(USHORT id, USHORT wNotify);
  64. void OnTimer();
  65. };