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.

142 lines
5.0 KiB

  1. *****************************************************************************************************************/
  2. /*****************************************************************************************************************/
  3. /*****************************************************************************************************************/
  4. /*****************************************************************************************************************/
  5. /*****************************************************************************************************************/
  6. /*****************************************************************************************************************/
  7. /////////////////////////////////////////////////////////////////////////////////////////////////////////////
  8. //can't do
  9. /////////////////////////////////////////////////////////////////////////////////////////////////////////////
  10. /*int doUndo();
  11. int doRedo();
  12. int doGroup();
  13. int doGroup()
  14. {
  15. PROPSHEETPAGE psp = {0}; //defines the property sheet pages
  16. HPROPSHEETPAGE ahpsp[10] = {0}; //an array to hold the page's HPROPSHEETPAGE handles
  17. PROPSHEETHEADER psh = {0}; //defines the property sheet
  18. SHAREDWIZDATA wizdata = {0}; //the shared data structure
  19. psp.pfnDlgProc = IntroDlgProc;
  20. intropage(ahpsp,psp,IDD_GROUP_INTRO,0,wizdata,IDS_ACCOUNT_TITLE);
  21. psp.pfnDlgProc = IntGeneralProc; definepage(ahpsp,psp,IDS_FOR_REAL,IDS_FOR_REAL_SUB,IDD_FOR_REAL,1,IDS_ACCOUNT_TITLE);
  22. psp.pfnDlgProc = IntGeneralProc; definepage(ahpsp,psp,IDS_DOMAIN,IDS_DOMAIN_SUB,IDD_DOMAIN_SELECTION,2,IDS_ACCOUNT_TITLE);
  23. psp.pfnDlgProc = IntGeneralProc; definepage(ahpsp,psp,IDS_CREDENTIALS,IDS_CREDENTIALS_SUB,IDD_CREDENTIALS,3,IDS_ACCOUNT_TITLE);
  24. psp.pfnDlgProc = IntGeneralProc; definepage(ahpsp,psp,IDS_SID_HISTORY,IDS_SID_HISTORY_SUB,IDD_SID_HISTORY,4,IDS_ACCOUNT_TITLE);
  25. psp.pfnDlgProc = IntGeneralProc; definepage(ahpsp,psp,IDS_USER_RIGHTS,IDS_USER_RIGHTS_SUB,IDD_USER_RIGHTS,5,IDS_ACCOUNT_TITLE);
  26. psp.pfnDlgProc = IntGeneralProc; definepage(ahpsp,psp,IDS_RENAMING,IDS_RENAMING_SUB,IDD_RENAMING,6,IDS_ACCOUNT_TITLE);
  27. psp.pfnDlgProc = IntGeneralProc; definepage(ahpsp,psp,IDS_REPLACE_EXISTING,IDS_REPLACE_EXISTING_SUB,IDD_REPLACE_EXISTING_GROUP_MEMBERS,9,IDS_ACCOUNT_TITLE);
  28. psp.pfnDlgProc = IntGeneralProc; definepage(ahpsp,psp,IDS_OU_SELECTION,IDS_OU_SELECTION_SUB,IDD_OU_SELECTION,7,IDS_ACCOUNT_TITLE);
  29. psp.pfnDlgProc = IntSelectionProc; definepage(ahpsp,psp,IDS_GROUP,IDS_GROUP_SUB,IDD_GROUP_SELECTION,8,IDS_ACCOUNT_TITLE);
  30. psp.pfnDlgProc = EndDlgProc;
  31. endpage(ahpsp,psp,IDD_GROUP_END,10,IDS_ACCOUNT_TITLE);
  32. defineSheet(ahpsp,psh,11,wizdata,10);
  33. return 0;
  34. }
  35. int doUndo()
  36. {
  37. PROPSHEETPAGE psp = {0}; //defines the property sheet pages
  38. HPROPSHEETPAGE ahpsp[3] = {0}; //an array to hold the page's HPROPSHEETPAGE handles
  39. PROPSHEETHEADER psh = {0}; //defines the property sheet
  40. SHAREDWIZDATA wizdata = {0}; //the shared data structure
  41. intropage(ahpsp,psp,IDD_INTRO_UNDO,0,wizdata,IDS_ACCOUNT_TITLE);
  42. psp.pfnDlgProc = IntGeneralProc; definepage(ahpsp,psp,IDS_UNDO,IDS_UNDO_SUB,IDD_UNDO,1,IDS_ACCOUNT_TITLE);
  43. psp.pfnDlgProc = EndDlgProc;
  44. endpage(ahpsp,psp,IDD_END_UNDO,2,IDS_ACCOUNT_TITLE);
  45. defineSheet(ahpsp,psh,3,wizdata,5);
  46. return 0;
  47. }
  48. int doRedo()
  49. {
  50. PROPSHEETPAGE psp = {0}; //defines the property sheet pages
  51. HPROPSHEETPAGE ahpsp[3] = {0}; //an array to hold the page's HPROPSHEETPAGE handles
  52. PROPSHEETHEADER psh = {0}; //defines the property sheet
  53. SHAREDWIZDATA wizdata = {0}; //the shared data structure
  54. psp.pfnDlgProc = IntroDlgProc;
  55. intropage(ahpsp,psp,IDD_INTRO_REDO,0,wizdata,IDS_ACCOUNT_TITLE);
  56. psp.pfnDlgProc = IntGeneralProc; definepage(ahpsp,psp,IDS_REDO,IDS_REDO_SUB,IDD_REDO,1,IDS_ACCOUNT_TITLE);
  57. psp.pfnDlgProc = EndDlgProc;
  58. endpage(ahpsp,psp,IDD_END_REDO,2,IDS_ACCOUNT_TITLE);
  59. defineSheet(ahpsp,psh,3,wizdata,6);
  60. return 0;
  61. }
  62. BOOL CALLBACK IntClosedProc (
  63. HWND hwndDlg,
  64. UINT uMsg,
  65. WPARAM wParam,
  66. LPARAM lParam
  67. )
  68. {
  69. //Process messages from the second interior page
  70. //Retrieve the shared user data from GWL_USERDATA
  71. // LPSHAREDWIZDATA pdata = (LPSHAREDWIZDATA) GetWindowLong(hwndDlg, GWL_USERDATA);
  72. LPSHAREDWIZDATA pdata = (LPSHAREDWIZDATA) GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
  73. switch (uMsg)
  74. {
  75. case WM_INITDIALOG :
  76. {
  77. //Get the PROPSHEETPAGE lParam value and load it into
  78. //DWL_USERDATA
  79. pdata = (LPSHAREDWIZDATA) ((LPPROPSHEETPAGE) lParam) -> lParam;
  80. // SetWindowLong(hwndDlg, GWL_USERDATA, (long) pdata);
  81. SetWindowLongPtr(hwndDlg, GWLP_USERDATA, (LONG_PTR) pdata);
  82. break;
  83. }
  84. case WM_NOTIFY :
  85. {
  86. LPNMHDR lpnm = (LPNMHDR) lParam;
  87. switch (lpnm->code)
  88. {
  89. case PSN_SETACTIVE : //Enable the Next and Back buttons
  90. PropSheet_SetWizButtons(GetParent(hwndDlg), PSWIZB_BACK | PSWIZB_NEXT);
  91. break;
  92. case PSN_WIZNEXT :
  93. //Handle a Next button click, if necessary
  94. break;
  95. case PSN_WIZBACK :
  96. break;
  97. case PSN_RESET :
  98. //Handle a Cancel button click, if necessary
  99. break;
  100. default :
  101. break;
  102. }
  103. }
  104. break;
  105. default:
  106. break;
  107. }
  108. return 0;
  109. }
  110. */