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.

202 lines
5.4 KiB

  1. #if !defined(AFX_PROPEDIT_H__28023930_BFAE_11D2_A4F8_00105A192534__INCLUDED_)
  2. #define AFX_PROPEDIT_H__28023930_BFAE_11D2_A4F8_00105A192534__INCLUDED_
  3. #if _MSC_VER >= 1000
  4. #pragma once
  5. #endif // _MSC_VER >= 1000
  6. // PropEdit.h : header file
  7. //
  8. /////////////////////////////////////////////////////////////////////////////
  9. // CPropEdit dialog
  10. class CPropEdit : public CDialog
  11. {
  12. // Construction
  13. public:
  14. void SetPropertyName(CString PropName);
  15. void SetPropertyValue(CString PropValue);
  16. void SetPropertyType (USHORT PropType);
  17. USHORT m_VT;
  18. CPropEdit(CWnd* pParent = NULL); // standard constructor
  19. // Dialog Data
  20. //{{AFX_DATA(CPropEdit)
  21. enum { IDD = IDD_PROPEDIT_DIALOG };
  22. CButton m_ButtonOk;
  23. CButton m_ButtonCancel;
  24. CString m_EditString;
  25. CString m_strPropName;
  26. //}}AFX_DATA
  27. // Overrides
  28. // ClassWizard generated virtual function overrides
  29. //{{AFX_VIRTUAL(CPropEdit)
  30. protected:
  31. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  32. //}}AFX_VIRTUAL
  33. // Implementation
  34. protected:
  35. // Generated message map functions
  36. //{{AFX_MSG(CPropEdit)
  37. //}}AFX_MSG
  38. DECLARE_MESSAGE_MAP()
  39. };
  40. /////////////////////////////////////////////////////////////////////////////
  41. // CPropEditList dialog
  42. class CPropEditList : public CDialog
  43. {
  44. // Construction
  45. public:
  46. CString ConvertListValueToCString(UINT Value);
  47. CString ConvertGUIDListValueToCString(GUID guidValue);
  48. void SetPropertyName(CString PropName);
  49. void SetPropertyValue(CString PropValue);
  50. void SetPropertyType (USHORT PropType);
  51. CPropEditList(CWnd* pParent = NULL); // standard constructor
  52. BOOL SetListValue(int ListValue);
  53. BOOL SetArray(BYTE* pArray,int nElements);
  54. BOOL DisplayListValues();
  55. BYTE* m_pArray;
  56. int m_nElements;
  57. int m_CurrentElementNum;
  58. int m_CurrentEntry;
  59. USHORT m_VT;
  60. // Dialog Data
  61. //{{AFX_DATA(CPropEditList)
  62. enum { IDD = IDD_PROPEDIT_LIST_DIALOG };
  63. CListCtrl m_ListValueListBox;
  64. CButton m_NumListValueDisplay;
  65. CButton m_ButtonOk;
  66. CButton m_ButtonCancel;
  67. CString m_EditString;
  68. CString m_strPropName;
  69. //}}AFX_DATA
  70. // Overrides
  71. // ClassWizard generated virtual function overrides
  72. //{{AFX_VIRTUAL(CPropEditList)
  73. protected:
  74. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  75. //}}AFX_VIRTUAL
  76. // Implementation
  77. protected:
  78. // Generated message map functions
  79. //{{AFX_MSG(CPropEditList)
  80. virtual BOOL OnInitDialog();
  81. afx_msg void OnClose();
  82. afx_msg void OnDestroy();
  83. afx_msg void OnDblclkListListctrl(NMHDR* pNMHDR, LRESULT* pResult);
  84. afx_msg void OnClickListListctrl(NMHDR* pNMHDR, LRESULT* pResult);
  85. //}}AFX_MSG
  86. DECLARE_MESSAGE_MAP()
  87. };
  88. /////////////////////////////////////////////////////////////////////////////
  89. // CPropEditFlags dialog
  90. class CPropEditFlags : public CDialog
  91. {
  92. // Construction
  93. public:
  94. CString ConvertFlagToCString(DWORD flag);
  95. void InitPossibleFlagValues();
  96. void SetPropID(USHORT iProp);
  97. void SetPropertyName(CString PropName);
  98. void SetPropertyValue(CString PropValue);
  99. void SetPropertyType (USHORT PropType);
  100. CPropEditFlags(CWnd* pParent = NULL); // standard constructor
  101. USHORT m_VT;
  102. USHORT m_PropID;
  103. DWORD m_CurrentValue;
  104. int m_CurrentEntry;
  105. // Dialog Data
  106. //{{AFX_DATA(CPropEditFlags)
  107. enum { IDD = IDD_PROPEDIT_FLAGS_DIALOG };
  108. CListCtrl m_FlagValueListBox;
  109. CButton m_CurrentFlagValue;
  110. CButton m_ButtonOk;
  111. CButton m_ButtonCancel;
  112. CString m_EditString;
  113. CString m_strPropName;
  114. //}}AFX_DATA
  115. // Overrides
  116. // ClassWizard generated virtual function overrides
  117. //{{AFX_VIRTUAL(CPropEditFlags)
  118. protected:
  119. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  120. //}}AFX_VIRTUAL
  121. // Implementation
  122. protected:
  123. // Generated message map functions
  124. //{{AFX_MSG(CPropEditFlags)
  125. virtual BOOL OnInitDialog();
  126. afx_msg void OnClose();
  127. afx_msg void OnDestroy();
  128. afx_msg void OnClickFlagsListctrl(NMHDR* pNMHDR, LRESULT* pResult);
  129. //}}AFX_MSG
  130. DECLARE_MESSAGE_MAP()
  131. };
  132. /////////////////////////////////////////////////////////////////////////////
  133. // CPropEditRange dialog
  134. class CPropEditRange : public CDialog
  135. {
  136. // Construction
  137. public:
  138. void SetPropertyName(CString PropName);
  139. void SetPropertyValue(CString PropValue);
  140. void SetPropertyType (USHORT PropType);
  141. CPropEditRange(CWnd* pParent = NULL); // standard constructor
  142. BOOL SetRangeValues(int Min, int Max, int Nom, int Inc);
  143. BOOL SetRangeValues(float Min, float Max, float Nom, float Inc);
  144. USHORT m_VT;
  145. // Dialog Data
  146. //{{AFX_DATA(CPropEditRange)
  147. enum { IDD = IDD_PROPEDIT_RANGE_DIALOG };
  148. CButton m_ButtonOk;
  149. CButton m_ButtonCancel;
  150. CString m_EditString;
  151. CString m_strPropName;
  152. CString m_Increment;
  153. CString m_Maximum;
  154. CString m_Minimum;
  155. CString m_Nominal;
  156. //}}AFX_DATA
  157. // Overrides
  158. // ClassWizard generated virtual function overrides
  159. //{{AFX_VIRTUAL(CPropEditRange)
  160. protected:
  161. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  162. //}}AFX_VIRTUAL
  163. // Implementation
  164. protected:
  165. // Generated message map functions
  166. //{{AFX_MSG(CPropEditRange)
  167. //}}AFX_MSG
  168. DECLARE_MESSAGE_MAP()
  169. };
  170. //{{AFX_INSERT_LOCATION}}
  171. // Microsoft Developer Studio will insert additional declarations immediately before the previous line.
  172. #endif // !defined(AFX_PROPEDIT_H__28023930_BFAE_11D2_A4F8_00105A192534__INCLUDED_)