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.

126 lines
5.3 KiB

  1. /*
  2. * SPSTUP.H - SwapFile interface for Setup. routines exported from cpwin386.cpl
  3. *
  4. * BUGBUG: this can go away once we do swapfiles right...
  5. */
  6. /*
  7. * Structure used with SetupSwapFile API.
  8. */
  9. typedef struct
  10. {
  11. unsigned long StpResBytes; /* The number of bytes that
  12. * Setup needs to reserve on the
  13. * indicated drive for further
  14. * Setup operations.
  15. */
  16. unsigned long PartFileSizeBytes; /* The size set (output), or the size
  17. * to be set (input) for the paging
  18. * SwapFile.
  19. */
  20. unsigned int PartFlags; /* Paging file flags, see bit
  21. * definitions below.
  22. */
  23. unsigned int Win300SpCopied; /* This is a BOOL. It controls the
  24. * user warning about the fact that
  25. * partition files are inherently
  26. * GLOBAL and that if the USER
  27. * has both a 3.00 and 3.10
  28. * installation he is going to stomp
  29. * the 3.00 installation unless he
  30. * behaves.
  31. *
  32. * NOTE that the display of this
  33. * warning is NOT controlled by the
  34. * Interact setting.
  35. *
  36. * NOTE that SetupSwapFile may change
  37. * this variable from TRUE -> FALSE
  38. * and that Setup should preserve
  39. * this change across subsequent
  40. * calls.
  41. *
  42. * Normally this is FALSE. Setup
  43. * should set this to TRUE iff SETUP
  44. * has copied SPART.PAR from a 3.00
  45. * directory as part of the setup
  46. * process. NOTE that this implies
  47. * several things:
  48. *
  49. * SETUP found a 3.00 dir.
  50. *
  51. * This is a new installation of
  52. * 3.10 into a directory DIFFERENT
  53. * than the 3.00 directory.
  54. *
  55. * Setup found an SPART.PAR in the
  56. * 3.00 directory to copy.
  57. *
  58. * An SPART.PAR did not already
  59. * exist in the 3.10 directory.
  60. */
  61. /*
  62. * The following two fields are UPPER-CASE DOS DRIVE LETTERS.
  63. */
  64. unsigned char StpResDrv; /* DOS drive of StpResBytes. */
  65. unsigned char PartDrv; /* DOS drive of PartFileSizeBytes. */
  66. LPCSTR szWinDir; /* NEW FOR CHICAGO: windows dir where we are installing too */
  67. } SprtData;
  68. /*
  69. * Structure used with SetupGetCurSetting API:
  70. */
  71. typedef struct
  72. {
  73. unsigned long PartCurSizeBytes; /* The size of the current SwapFile
  74. * (output).
  75. */
  76. unsigned int PartFlags; /* Paging file flags (output), see
  77. * bit definitions below.
  78. */
  79. unsigned char PartDrv; /* DOS drive of CurSizeBytes (output).
  80. */
  81. } SprtSetData;
  82. /*
  83. * Bit definitions for PartFlags bit field:
  84. *
  85. * For SetupSwapFile() API only
  86. *
  87. * PART_IS_TEMP
  88. * PART_IS_PERM
  89. * PART_OFF
  90. * PART_NO_SPACE
  91. * PART_UCANCEL
  92. *
  93. * are valid. For SetupGetCurSetting() API only
  94. *
  95. * PART_IS_TEMP
  96. * PART_IS_PERM
  97. * PART_OFF
  98. * PART_FAST
  99. *
  100. * are valid.
  101. */
  102. #define PART_IS_TEMP 0x0001 /* Setting is temporary swapfile. */
  103. #define PART_IS_PERM 0x0002 /* Setting is permanent swapfile. */
  104. #define PART_OFF 0x0004 /* USER requested paging OFF. */
  105. #define PART_FAST 0x0008 /* Only through SetupGetCurSetting API -
  106. * if PART_IS_PERM means USING 32-BIT
  107. * ACCESS.
  108. */
  109. #define PART_NO_SPACE 0x0010 /* No setting, insufficient disk space. */
  110. #define PART_UCANCEL 0x0020 /* USER CANCELED in interactive mode. */
  111. typedef BOOL (FAR PASCAL *SWAPCURSETPROC)(SprtSetData FAR *SetData);
  112. typedef BOOL (FAR PASCAL *SWAPFILEPROC)(HWND, BOOL bInteract, BOOL bCreate, SprtData FAR *);