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.

439 lines
10 KiB

  1. #if !defined(_CHOOSEFILENAMEPAGE_H)
  2. #define _CHOOSEFILENAMEPAGE_H
  3. #if _MSC_VER > 1000
  4. #pragma once
  5. #endif // _MSC_VER > 1000
  6. // ChooseFileNamePage.h : header file
  7. //
  8. #include "Certificat.h"
  9. /////////////////////////////////////////////////////////////////////////////
  10. // CChooseFileNamePage dialog
  11. //class CCertificate;
  12. class CChooseFileNamePage : public CIISWizardPage
  13. {
  14. DECLARE_DYNCREATE(CChooseFileNamePage)
  15. // Construction
  16. public:
  17. CChooseFileNamePage( UINT id = 0,
  18. UINT defaultID = 0,
  19. UINT extID = 0,
  20. UINT filterID = 0,
  21. CString * pOutFileName = NULL,
  22. CString csAdditionalInfo = _T("")
  23. );
  24. ~CChooseFileNamePage();
  25. // Dialog Data
  26. //{{AFX_DATA(CChooseCAPage)
  27. CString m_FileName;
  28. //}}AFX_DATA
  29. BOOL m_DoReplaceFile;
  30. UINT m_id, m_defaultID;
  31. CString ext, filter;
  32. CString * m_pOutFileName;
  33. CString m_AdditionalInfo;
  34. // Overrides
  35. virtual void FileNameChanged()
  36. {
  37. }
  38. virtual BOOL IsReadFileDlg()
  39. {
  40. ASSERT(FALSE);
  41. return FALSE;
  42. }
  43. // ClassWizard generate virtual function overrides
  44. //{{AFX_VIRTUAL(CChooseCAPage)
  45. protected:
  46. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  47. public:
  48. virtual LRESULT OnWizardNext()
  49. {
  50. ASSERT(FALSE);
  51. return 1;
  52. }
  53. virtual LRESULT OnWizardBack();
  54. virtual BOOL OnSetActive();
  55. //}}AFX_VIRTUAL
  56. // Implementation
  57. protected:
  58. void GetDefaultFileName(CString& str);
  59. void Browse(CString& strPath, CString& strFile);
  60. LRESULT DoWizardNext(LRESULT id);
  61. // Generated message map functions
  62. //{{AFX_MSG(CChooseCAPage)
  63. afx_msg void OnBrowseBtn();
  64. virtual BOOL OnInitDialog();
  65. afx_msg void OnChangeFileName();
  66. //}}AFX_MSG
  67. DECLARE_MESSAGE_MAP()
  68. };
  69. class CChooseReadFileName : public CChooseFileNamePage
  70. {
  71. DECLARE_DYNCREATE(CChooseReadFileName)
  72. // Construction
  73. public:
  74. CChooseReadFileName( UINT id = 0,
  75. UINT defaultID = 0,
  76. UINT extID = 0,
  77. UINT filterID = 0,
  78. CString * pOutFileName = NULL,
  79. CString csAdditionalInfo = _T("")
  80. );
  81. ~CChooseReadFileName()
  82. {
  83. }
  84. // Overrides
  85. virtual void FileNameChanged()
  86. {
  87. }
  88. virtual BOOL IsReadFileDlg()
  89. {
  90. return TRUE;
  91. }
  92. // ClassWizard generate virtual function overrides
  93. //{{AFX_VIRTUAL(CChooseCAPage)
  94. protected:
  95. // virtual void DoDataExchange(CDataExchange* pDX)
  96. // {
  97. // CChooseFileNamePage::DoDataExchange(pDX);
  98. // }
  99. public:
  100. virtual LRESULT OnWizardNext();
  101. virtual LRESULT OnWizardBack() {return 1;}
  102. virtual BOOL OnSetActive()
  103. {
  104. return CChooseFileNamePage::OnSetActive();
  105. }
  106. //}}AFX_VIRTUAL
  107. // Implementation
  108. protected:
  109. // Generated message map functions
  110. //{{AFX_MSG(CChooseCAPage)
  111. afx_msg void OnBrowseBtn();
  112. virtual BOOL OnInitDialog();
  113. //}}AFX_MSG
  114. DECLARE_MESSAGE_MAP()
  115. };
  116. class CChooseWriteFileName : public CChooseFileNamePage
  117. {
  118. DECLARE_DYNCREATE(CChooseWriteFileName)
  119. // Construction
  120. public:
  121. CChooseWriteFileName(UINT id = 0,
  122. UINT defaultID = 0,
  123. UINT extID = 0,
  124. UINT filterID = 0,
  125. CString * pOutFileName = NULL,
  126. CString csAdditionalInfo = _T("")
  127. );
  128. ~CChooseWriteFileName() {}
  129. // Overrides
  130. virtual void FileNameChanged() {}
  131. virtual BOOL IsReadFileDlg()
  132. {
  133. return FALSE;
  134. }
  135. // ClassWizard generate virtual function overrides
  136. //{{AFX_VIRTUAL(CChooseCAPage)
  137. protected:
  138. // virtual void DoDataExchange(CDataExchange* pDX)
  139. // {
  140. // CChooseFileNamePage::DoDataExchange(pDX);
  141. // }
  142. public:
  143. virtual LRESULT OnWizardNext();
  144. virtual LRESULT OnWizardBack() {return 1;}
  145. virtual BOOL OnSetActive()
  146. {
  147. return CChooseFileNamePage::OnSetActive();
  148. }
  149. //}}AFX_VIRTUAL
  150. // Implementation
  151. protected:
  152. // Generated message map functions
  153. //{{AFX_MSG(CChooseCAPage)
  154. afx_msg void OnBrowseBtn();
  155. virtual BOOL OnInitDialog();
  156. //}}AFX_MSG
  157. DECLARE_MESSAGE_MAP()
  158. };
  159. class CChooseRespFile : public CChooseReadFileName
  160. {
  161. DECLARE_DYNCREATE(CChooseRespFile)
  162. // Construction
  163. public:
  164. CChooseRespFile(CCertificate * pCert = NULL);
  165. ~CChooseRespFile();
  166. enum
  167. {
  168. IDD_PAGE_PREV = IDD_PAGE_WIZ_PENDING_WHAT_TODO,
  169. IDD_PAGE_NEXT = IDD_PAGE_WIZ_INSTALL_RESP
  170. #ifdef ENABLE_W3SVC_SSL_PAGE
  171. ,IDD_PAGE_NEXT_INSTALL_W3SVC_ONLY = IDD_PAGE_WIZ_GET_SSL_PORT
  172. #endif
  173. };
  174. // Dialog Data
  175. //{{AFX_DATA(CChooseRespFile)
  176. enum { IDD = IDD_PAGE_WIZ_GETRESP_FILE };
  177. // NOTE - ClassWizard will add data members here.
  178. // DO NOT EDIT what you see in these blocks of generated code !
  179. //}}AFX_DATA
  180. CCertificate * m_pCert;
  181. // Overrides
  182. virtual void FileNameChanged();
  183. // ClassWizard generate virtual function overrides
  184. //{{AFX_VIRTUAL(CChooseRespFile)
  185. public:
  186. virtual LRESULT OnWizardNext();
  187. virtual LRESULT OnWizardBack();
  188. protected:
  189. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  190. //}}AFX_VIRTUAL
  191. // Implementation
  192. protected:
  193. // Generated message map functions
  194. //{{AFX_MSG(CChooseRespFile)
  195. afx_msg HBRUSH OnCtlColor(CDC * pDC, CWnd * pWnd, UINT nCtlColor);
  196. //}}AFX_MSG
  197. DECLARE_MESSAGE_MAP()
  198. };
  199. class CChooseReqFile : public CChooseWriteFileName
  200. {
  201. DECLARE_DYNCREATE(CChooseReqFile)
  202. // Construction
  203. public:
  204. CChooseReqFile(CCertificate * pCert = NULL);
  205. ~CChooseReqFile();
  206. enum
  207. {
  208. IDD_PAGE_PREV = IDD_PAGE_WIZ_GEO_INFO,
  209. IDD_PAGE_NEXT = IDD_PAGE_WIZ_REQUEST_DUMP
  210. };
  211. // Dialog Data
  212. //{{AFX_DATA(CChooseReqFile)
  213. enum { IDD = IDD_PAGE_WIZ_CHOOSE_FILENAME };
  214. // NOTE - ClassWizard will add data members here.
  215. // DO NOT EDIT what you see in these blocks of generated code !
  216. //}}AFX_DATA
  217. CCertificate * m_pCert;
  218. // Overrides
  219. // ClassWizard generate virtual function overrides
  220. //{{AFX_VIRTUAL(CChooseReqFile)
  221. public:
  222. virtual LRESULT OnWizardNext();
  223. virtual LRESULT OnWizardBack();
  224. protected:
  225. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  226. //}}AFX_VIRTUAL
  227. // Implementation
  228. protected:
  229. // Generated message map functions
  230. //{{AFX_MSG(CChooseReqFile)
  231. // NOTE: the ClassWizard will add member functions here
  232. //}}AFX_MSG
  233. DECLARE_MESSAGE_MAP()
  234. };
  235. class CChooseReqFileRenew : public CChooseWriteFileName
  236. {
  237. DECLARE_DYNCREATE(CChooseReqFileRenew)
  238. // Construction
  239. public:
  240. CChooseReqFileRenew(CCertificate * pCert = NULL);
  241. ~CChooseReqFileRenew();
  242. enum
  243. {
  244. IDD_PAGE_PREV = IDD_PAGE_WIZ_CHOOSE_CATYPE,
  245. IDD_PAGE_NEXT = IDD_PAGE_WIZ_REQUEST_DUMP_RENEW
  246. };
  247. // Dialog Data
  248. //{{AFX_DATA(CChooseReqFileRenew)
  249. enum { IDD = IDD_PAGE_WIZ_CHOOSE_FILENAME_RENEW };
  250. // NOTE - ClassWizard will add data members here.
  251. // DO NOT EDIT what you see in these blocks of generated code !
  252. //}}AFX_DATA
  253. CCertificate * m_pCert;
  254. // Overrides
  255. // ClassWizard generate virtual function overrides
  256. //{{AFX_VIRTUAL(CChooseReqFileRenew)
  257. public:
  258. virtual LRESULT OnWizardNext();
  259. virtual LRESULT OnWizardBack();
  260. protected:
  261. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  262. //}}AFX_VIRTUAL
  263. // Implementation
  264. protected:
  265. // Generated message map functions
  266. //{{AFX_MSG(CChooseReqFileRenew)
  267. // NOTE: the ClassWizard will add member functions here
  268. //}}AFX_MSG
  269. DECLARE_MESSAGE_MAP()
  270. };
  271. class CChooseKeyFile : public CChooseReadFileName
  272. {
  273. DECLARE_DYNCREATE(CChooseKeyFile)
  274. // Construction
  275. public:
  276. CChooseKeyFile(CCertificate * pCert = NULL);
  277. ~CChooseKeyFile();
  278. enum
  279. {
  280. IDD_PAGE_PREV = IDD_PAGE_WIZ_GET_WHAT,
  281. IDD_PAGE_NEXT = IDD_PAGE_WIZ_GET_PASSWORD,
  282. };
  283. // Dialog Data
  284. //{{AFX_DATA(CChooseKeyFile)
  285. enum { IDD = IDD_PAGE_WIZ_GETKEY_FILE };
  286. // NOTE - ClassWizard will add data members here.
  287. // DO NOT EDIT what you see in these blocks of generated code !
  288. //}}AFX_DATA
  289. CCertificate * m_pCert;
  290. // Overrides
  291. // ClassWizard generate virtual function overrides
  292. //{{AFX_VIRTUAL(CChooseKeyFile)
  293. public:
  294. virtual LRESULT OnWizardNext();
  295. virtual LRESULT OnWizardBack();
  296. protected:
  297. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  298. //}}AFX_VIRTUAL
  299. // Implementation
  300. protected:
  301. // Generated message map functions
  302. //{{AFX_MSG(CChooseKeyFile)
  303. // NOTE: the ClassWizard will add member functions here
  304. //}}AFX_MSG
  305. DECLARE_MESSAGE_MAP()
  306. };
  307. class CChooseImportPFXFile : public CChooseReadFileName
  308. {
  309. DECLARE_DYNCREATE(CChooseImportPFXFile)
  310. // Construction
  311. public:
  312. CChooseImportPFXFile(CCertificate * pCert = NULL);
  313. ~CChooseImportPFXFile();
  314. enum
  315. {
  316. IDD_PAGE_PREV = IDD_PAGE_WIZ_GET_WHAT,
  317. IDD_PAGE_NEXT = IDD_PAGE_WIZ_GET_IMPORT_PFX_PASSWORD,
  318. };
  319. // Dialog Data
  320. //{{AFX_DATA(CChooseImportPFXFile)
  321. enum { IDD = IDD_PAGE_WIZ_GET_IMPORT_PFX_FILE };
  322. BOOL m_MarkAsExportable;
  323. //}}AFX_DATA
  324. CCertificate * m_pCert;
  325. // Overrides
  326. // ClassWizard generate virtual function overrides
  327. //{{AFX_VIRTUAL(CChooseImportPFXFile)
  328. public:
  329. virtual LRESULT OnWizardNext();
  330. virtual LRESULT OnWizardBack();
  331. protected:
  332. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  333. //}}AFX_VIRTUAL
  334. // Implementation
  335. protected:
  336. // Generated message map functions
  337. //{{AFX_MSG(CChooseImportPFXFile)
  338. // NOTE: the ClassWizard will add member functions here
  339. afx_msg void OnExportable();
  340. //}}AFX_MSG
  341. DECLARE_MESSAGE_MAP()
  342. };
  343. class CChooseExportPFXFile : public CChooseWriteFileName
  344. {
  345. DECLARE_DYNCREATE(CChooseExportPFXFile)
  346. // Construction
  347. public:
  348. CChooseExportPFXFile(CCertificate * pCert = NULL);
  349. ~CChooseExportPFXFile();
  350. enum
  351. {
  352. IDD_PAGE_PREV = IDD_PAGE_WIZ_MANAGE_CERT,
  353. IDD_PAGE_NEXT = IDD_PAGE_WIZ_GET_EXPORT_PFX_PASSWORD,
  354. };
  355. // Dialog Data
  356. //{{AFX_DATA(CChooseExportPFXFile)
  357. enum { IDD = IDD_PAGE_WIZ_GET_EXPORT_PFX_FILE };
  358. // NOTE - ClassWizard will add data members here.
  359. // DO NOT EDIT what you see in these blocks of generated code !
  360. //}}AFX_DATA
  361. CCertificate * m_pCert;
  362. // Overrides
  363. // ClassWizard generate virtual function overrides
  364. //{{AFX_VIRTUAL(CChooseExportPFXFile)
  365. public:
  366. virtual LRESULT OnWizardNext();
  367. virtual LRESULT OnWizardBack();
  368. protected:
  369. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  370. //}}AFX_VIRTUAL
  371. // Implementation
  372. protected:
  373. // Generated message map functions
  374. //{{AFX_MSG(CChooseExportPFXFile)
  375. // NOTE: the ClassWizard will add member functions here
  376. //}}AFX_MSG
  377. DECLARE_MESSAGE_MAP()
  378. };
  379. //{{AFX_INSERT_LOCATION}}
  380. // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
  381. #endif // !defined(_CHOOSEFILENAMEPAGE_H)