Source code of Windows XP (NT5)
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.

99 lines
3.2 KiB

  1. // watcher.h : main header file for the WATCHER application
  2. //
  3. #if !defined(AFX_WATCHER_H__691AA721_59DC_4A70_AB0E_224249D74256__INCLUDED_)
  4. #define AFX_WATCHER_H__691AA721_59DC_4A70_AB0E_224249D74256__INCLUDED_
  5. #if _MSC_VER > 1000
  6. #pragma once
  7. #endif // _MSC_VER > 1000
  8. #ifndef __AFXWIN_H__
  9. #error include 'stdafx.h' before including this file for PCH
  10. #endif
  11. #include "resource.h" // main symbols
  12. #include "ParameterDialog.h"
  13. /////////////////////////////////////////////////////////////////////////////
  14. // CWatcherApp:
  15. // See watcher.cpp for the implementation of this class
  16. //
  17. class CWatcherApp : public CWinApp
  18. {
  19. public:
  20. //void AddParameter();
  21. CWatcherApp();
  22. // Overrides
  23. // ClassWizard generated virtual function overrides
  24. //{{AFX_VIRTUAL(CWatcherApp)
  25. public:
  26. // Making this public so that the Manage Dialog
  27. // can access this function.
  28. int GetParametersByIndex(int dwIndex,
  29. CString &sess,
  30. CString &mac,
  31. CString &com,
  32. UINT &port,
  33. int &lang,
  34. int &tc,
  35. int &hist,
  36. CString &lgnName,
  37. CString &lgnPasswd
  38. );
  39. void Refresh(ParameterDialog &pd, BOOLEAN del);
  40. HKEY & GetKey();
  41. virtual BOOL InitInstance();
  42. virtual void ParseCommandLine(CCommandLineInfo& rCmdInfo);
  43. virtual BOOL ProcessShellCommand(CCommandLineInfo &rCmdInfo);
  44. //}}AFX_VIRTUAL
  45. // Implementation
  46. //{{AFX_MSG(CWatcherApp)
  47. afx_msg void OnAppAbout();
  48. afx_msg void OnAppExit();
  49. //}}AFX_MSG
  50. DECLARE_MESSAGE_MAP()
  51. protected:
  52. // Reads in the parameters from the registry
  53. // corresponding to the session.
  54. void DeleteSession(CDocument *wdoc);
  55. BOOLEAN EqualParameters(ParameterDialog & pd1, ParameterDialog & pd2);
  56. int GetParameters(CString &mac,
  57. CString &com,
  58. CString &lgnName,
  59. CString &lgnPasswd,
  60. UINT &port,
  61. int &lang,
  62. int &tc,
  63. int & hist,
  64. HKEY &child
  65. );
  66. // does everything the document manager does when asked to
  67. // create a new document.
  68. void CreateNewSession(CString &mac,
  69. CString &com,
  70. UINT port,
  71. int lang,
  72. int tc,
  73. int hist,
  74. CString &lgnName,
  75. CString &lgnPasswd,
  76. CString &sess
  77. );
  78. BOOL LoadRegistryParameters();
  79. afx_msg void OnHelp();
  80. afx_msg void OnFileManage();
  81. HKEY m_hkey;
  82. CMultiDocTemplate * m_pDocTemplate;
  83. CDialog *m_pManageDialog;
  84. };
  85. /////////////////////////////////////////////////////////////////////////////
  86. //{{AFX_INSERT_LOCATION}}
  87. // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
  88. #endif // !defined(AFX_WATCHER_H__691AA721_59DC_4A70_AB0E_224249D74256__INCLUDED_)