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.

160 lines
4.8 KiB

  1. /*++
  2. Copyright (C) 1998-1999 Microsoft Corporation
  3. Module Name:
  4. fileprop.h
  5. Abstract:
  6. Header file for the files property page.
  7. --*/
  8. #ifndef _FILEPROP_H_
  9. #define _FILEPROP_H_
  10. #if _MSC_VER >= 1000
  11. #pragma once
  12. #endif // _MSC_VER >= 1000
  13. #include "smlogqry.h" // For shared property page data structure
  14. #include "smproppg.h" // Base class
  15. #include "smcfghlp.h"
  16. // Dialog controls
  17. #define IDD_FILES_PROP 500
  18. #define IDC_FILE_FIRST_HELP_CTRL_ID 507
  19. #define IDC_FILES_LOG_TYPE_CAPTION 501
  20. #define IDC_FILES_NAME_GROUP 502
  21. #define IDC_FILES_COMMENT_CAPTION 503
  22. #define IDC_FILES_SAMPLE_CAPTION 504
  23. #define IDC_FILES_FIRST_SERIAL_CAPTION 505
  24. #define IDC_FILES_SUFFIX_CAPTION 506
  25. #define IDC_FILES_COMMENT_EDIT 507
  26. #define IDC_FILES_LOG_TYPE_COMBO 508
  27. #define IDC_CFG_BTN 509
  28. #define IDC_FILES_AUTO_SUFFIX_CHK 510
  29. #define IDC_FILES_SUFFIX_COMBO 511
  30. #define IDC_FILES_FIRST_SERIAL_EDIT 512
  31. #define IDC_FILES_SAMPLE_DISPLAY 513
  32. #define IDC_FILES_OVERWRITE_CHK 514
  33. class CSmLogQuery;
  34. /////////////////////////////////////////////////////////////////////////////
  35. // CFilesProperty dialog
  36. class CFilesProperty : public CSmPropertyPage
  37. {
  38. friend class CFileLogs;
  39. friend class CSqlProp;
  40. DECLARE_DYNCREATE(CFilesProperty)
  41. // Construction
  42. public:
  43. CFilesProperty(MMC_COOKIE mmcCookie, LONG_PTR hConsole);
  44. CFilesProperty();
  45. virtual ~CFilesProperty();
  46. // Dialog Data
  47. //{{AFX_DATA(CFilesProperty)
  48. enum { IDD = IDD_FILES_PROP };
  49. CString m_strCommentText;
  50. CString m_strLogName;
  51. int m_iLogFileType;
  52. CString m_strSampleFileName;
  53. int m_dwSuffix;
  54. DWORD m_dwSerialNumber;
  55. BOOL m_bAutoNameSuffix;
  56. BOOL m_bOverWriteFile;
  57. //}}AFX_DATA
  58. // Overrides
  59. // ClassWizard generate virtual function overrides
  60. //{{AFX_VIRTUAL(CFilesProperty)
  61. public:
  62. protected:
  63. virtual void OnFinalRelease();
  64. virtual BOOL OnSetActive();
  65. virtual BOOL OnKillActive();
  66. virtual BOOL OnApply();
  67. virtual void OnCancel();
  68. virtual BOOL OnInitDialog();
  69. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  70. virtual void PostNcDestroy();
  71. //}}AFX_VIRTUAL
  72. // Implementation
  73. protected:
  74. virtual INT GetFirstHelpCtrlId ( void ) { return IDC_FILE_FIRST_HELP_CTRL_ID; }; // Subclass must override.
  75. virtual BOOL IsValidLocalData();
  76. // Generated message map functions
  77. //{{AFX_MSG(CFilesProperty)
  78. afx_msg void OnAutoSuffixChk();
  79. afx_msg void OnOverWriteChk();
  80. afx_msg void OnChangeFilesCommentEdit();
  81. afx_msg void OnChangeFilesFirstSerialEdit();
  82. afx_msg void OnKillfocusFilesCommentEdit();
  83. afx_msg void OnKillfocusFirstSerialEdit();
  84. afx_msg void OnSelendokFilesLogFileTypeCombo();
  85. afx_msg void OnSelendokFilesSuffixCombo();
  86. afx_msg void OnKillfocusFilesSuffixCombo();
  87. afx_msg void OnKillfocusFilesLogFileTypeCombo();
  88. afx_msg void OnCfgBtn();
  89. //}}AFX_MSG
  90. DECLARE_MESSAGE_MAP()
  91. // Generated OLE dispatch map functions
  92. //{{AFX_DISPATCH(CFilesProperty)
  93. // NOTE - the ClassWizard will add and remove member functions here.
  94. //}}AFX_DISPATCH
  95. DECLARE_DISPATCH_MAP()
  96. DECLARE_INTERFACE_MAP()
  97. private:
  98. BOOL UpdateSampleFileName( void );
  99. void EnableSerialNumber( void );
  100. void HandleLogTypeChange( void );
  101. BOOL UpdateSharedData( BOOL bUpdateModel );
  102. DWORD ExtractDSN ( CString& rstrDSN );
  103. DWORD ExtractLogSetName ( CString& rstrLogSetName );
  104. enum eValueRange {
  105. eMinFileLimit = 1,
  106. eMaxFileLimit = 0x00000FFF, // * 0x0100000 = 0xFFFFFFF - no size restriction
  107. // for non-binary and circ files
  108. eMaxCtrSeqBinFileLimit = 0x00000FFF, // * 0x0100000 = 0xFFFFFFF - for binary files
  109. eMaxTrcSeqBinFileLimit = 0x30000000, // 0x30000000 - for trace seq binary files
  110. eMinSqlRecordsLimit = 0x00000004,
  111. eMaxSqlRecordsLimit = 0x30000000, // 0x30000000 - for SQL logs
  112. eMinFirstSerial = 0,
  113. eMaxFirstSerial = 999999
  114. };
  115. DWORD m_dwLogFileTypeValue;
  116. DWORD m_dwAppendMode;
  117. DWORD m_dwSuffixValue;
  118. DWORD m_dwSuffixIndexNNNNNN;
  119. DWORD m_dwMaxSizeInternal;
  120. CString m_strFileBaseName;
  121. CString m_strFolderName;
  122. CString m_strSqlName;
  123. DWORD m_dwSubDlgFocusCtrl;
  124. };
  125. //{{AFX_INSERT_LOCATION}}
  126. // Microsoft Developer Studio will insert additional declarations immediately before the previous line.
  127. #endif // _FILEPROP_H_