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.

1079 lines
36 KiB

  1. /*****************************************************************************\
  2. * *
  3. * prsht.h - - Interface for the Windows Property Sheet Pages *
  4. * *
  5. * Version 1.0 *
  6. * *
  7. * Copyright (c) Microsoft Corporation. All rights reserved. *
  8. * *
  9. \*****************************************************************************/
  10. #ifndef _PRSHT_H_
  11. #define _PRSHT_H_
  12. #ifndef _WINRESRC_
  13. #ifndef _WIN32_IE
  14. #define _WIN32_IE 0x0501
  15. #else
  16. #if (_WIN32_IE < 0x0400) && defined(_WIN32_WINNT) && (_WIN32_WINNT >= 0x0500)
  17. #error _WIN32_IE setting conflicts with _WIN32_WINNT setting
  18. #endif
  19. #endif
  20. #endif
  21. //
  22. // Define API decoration for direct importing of DLL references.
  23. //
  24. #ifndef WINCOMMCTRLAPI
  25. #if !defined(_COMCTL32_) && defined(_WIN32)
  26. #define WINCOMMCTRLAPI DECLSPEC_IMPORT
  27. #else
  28. #define WINCOMMCTRLAPI
  29. #endif
  30. #endif // WINCOMMCTRLAPI
  31. #ifndef CCSIZEOF_STRUCT
  32. #define CCSIZEOF_STRUCT(structname, member) (((int)((LPBYTE)(&((structname*)0)->member) - ((LPBYTE)((structname*)0)))) + sizeof(((structname*)0)->member))
  33. #endif
  34. //
  35. // For compilers that don't support nameless unions
  36. //
  37. #ifndef DUMMYUNIONNAME
  38. #ifdef NONAMELESSUNION
  39. #define DUMMYUNIONNAME u
  40. #define DUMMYUNIONNAME2 u2
  41. #define DUMMYUNIONNAME3 u3
  42. #define DUMMYUNIONNAME4 u4
  43. #define DUMMYUNIONNAME5 u5
  44. #else
  45. #define DUMMYUNIONNAME
  46. #define DUMMYUNIONNAME2
  47. #define DUMMYUNIONNAME3
  48. #define DUMMYUNIONNAME4
  49. #define DUMMYUNIONNAME5
  50. #endif
  51. #endif // DUMMYUNIONNAME
  52. #ifdef _WIN64
  53. #include <pshpack8.h>
  54. #else
  55. #include <pshpack4.h>
  56. #endif
  57. #ifdef __cplusplus
  58. extern "C" {
  59. #endif
  60. #ifndef SNDMSG
  61. #ifdef __cplusplus
  62. #ifndef _MAC
  63. #define SNDMSG ::SendMessage
  64. #else
  65. #define SNDMSG ::AfxSendMessage
  66. #endif
  67. #else
  68. #ifndef _MAC
  69. #define SNDMSG SendMessage
  70. #else
  71. #define SNDMSG AfxSendMessage
  72. #endif
  73. #endif
  74. #endif // ifndef SNDMSG
  75. #define MAXPROPPAGES 100
  76. struct _PSP;
  77. typedef struct _PSP * HPROPSHEETPAGE;
  78. #ifndef MIDL_PASS
  79. struct _PROPSHEETPAGEA;
  80. struct _PROPSHEETPAGEW;
  81. #endif
  82. typedef UINT (CALLBACK *LPFNPSPCALLBACKA)(HWND hwnd, UINT uMsg, struct _PROPSHEETPAGEA *ppsp);
  83. typedef UINT (CALLBACK *LPFNPSPCALLBACKW)(HWND hwnd, UINT uMsg, struct _PROPSHEETPAGEW *ppsp);
  84. #ifdef UNICODE
  85. #define LPFNPSPCALLBACK LPFNPSPCALLBACKW
  86. #else
  87. #define LPFNPSPCALLBACK LPFNPSPCALLBACKA
  88. #endif
  89. #define PSP_DEFAULT 0x00000000
  90. #define PSP_DLGINDIRECT 0x00000001
  91. #define PSP_USEHICON 0x00000002
  92. #define PSP_USEICONID 0x00000004
  93. #define PSP_USETITLE 0x00000008
  94. #define PSP_RTLREADING 0x00000010
  95. #define PSP_HASHELP 0x00000020
  96. #define PSP_USEREFPARENT 0x00000040
  97. #define PSP_USECALLBACK 0x00000080
  98. #define PSP_PREMATURE 0x00000400
  99. #if (_WIN32_IE >= 0x0400)
  100. //----- New flags for wizard97 --------------
  101. #define PSP_HIDEHEADER 0x00000800
  102. #define PSP_USEHEADERTITLE 0x00001000
  103. #define PSP_USEHEADERSUBTITLE 0x00002000
  104. //-------------------------------------------
  105. #endif
  106. #if (_WIN32_WINNT >= 0x0501) || ISOLATION_AWARE_ENABLED
  107. #define PSP_USEFUSIONCONTEXT 0x00004000
  108. #endif
  109. #if (_WIN32_IE >= 0x0500)
  110. #define PSPCB_ADDREF 0
  111. #endif
  112. #define PSPCB_RELEASE 1
  113. #define PSPCB_CREATE 2
  114. #define PROPSHEETPAGEA_V1_SIZE CCSIZEOF_STRUCT(PROPSHEETPAGEA, pcRefParent)
  115. #define PROPSHEETPAGEW_V1_SIZE CCSIZEOF_STRUCT(PROPSHEETPAGEW, pcRefParent)
  116. #define PROPSHEETPAGEA_V2_SIZE CCSIZEOF_STRUCT(PROPSHEETPAGEA, pszHeaderSubTitle)
  117. #define PROPSHEETPAGEW_V2_SIZE CCSIZEOF_STRUCT(PROPSHEETPAGEW, pszHeaderSubTitle)
  118. #ifdef _WIN32
  119. typedef LPCDLGTEMPLATE PROPSHEETPAGE_RESOURCE;
  120. #else
  121. typedef const VOID* PROPSHEETPAGE_RESOURCE;
  122. #endif
  123. #define PROPSHEETPAGEA_V1_FIELDS \
  124. DWORD dwSize; \
  125. DWORD dwFlags; \
  126. HINSTANCE hInstance; \
  127. union \
  128. { \
  129. LPCSTR pszTemplate; \
  130. PROPSHEETPAGE_RESOURCE pResource; \
  131. } DUMMYUNIONNAME; \
  132. union \
  133. { \
  134. HICON hIcon; \
  135. LPCSTR pszIcon; \
  136. } DUMMYUNIONNAME2; \
  137. LPCSTR pszTitle; \
  138. DLGPROC pfnDlgProc; \
  139. LPARAM lParam; \
  140. LPFNPSPCALLBACKA pfnCallback; \
  141. UINT *pcRefParent; \
  142. #define PROPSHEETPAGEW_V1_FIELDS \
  143. DWORD dwSize; \
  144. DWORD dwFlags; \
  145. HINSTANCE hInstance; \
  146. union \
  147. { \
  148. LPCWSTR pszTemplate; \
  149. PROPSHEETPAGE_RESOURCE pResource; \
  150. } DUMMYUNIONNAME; \
  151. union \
  152. { \
  153. HICON hIcon; \
  154. LPCWSTR pszIcon; \
  155. } DUMMYUNIONNAME2; \
  156. LPCWSTR pszTitle; \
  157. DLGPROC pfnDlgProc; \
  158. LPARAM lParam; \
  159. LPFNPSPCALLBACKW pfnCallback; \
  160. UINT *pcRefParent; \
  161. #if (_WIN32_WINNT >= 0x0501) || ISOLATION_AWARE_ENABLED
  162. #define _PROPSHEETPAGEA_V3 _PROPSHEETPAGEA
  163. #define _PROPSHEETPAGEW_V3 _PROPSHEETPAGEW
  164. #elif (_WIN32_IE >= 0x0400)
  165. #define _PROPSHEETPAGEA_V2 _PROPSHEETPAGEA
  166. #define _PROPSHEETPAGEW_V2 _PROPSHEETPAGEW
  167. #else
  168. #define _PROPSHEETPAGEA_V1 _PROPSHEETPAGEA
  169. #define _PROPSHEETPAGEW_V1 _PROPSHEETPAGEW
  170. #endif
  171. typedef struct _PROPSHEETPAGEA_V1
  172. {
  173. PROPSHEETPAGEA_V1_FIELDS
  174. } PROPSHEETPAGEA_V1, *LPPROPSHEETPAGEA_V1;
  175. typedef const PROPSHEETPAGEA_V1 *LPCPROPSHEETPAGEA_V1;
  176. typedef struct _PROPSHEETPAGEA_V2
  177. {
  178. PROPSHEETPAGEA_V1_FIELDS
  179. LPCSTR pszHeaderTitle; // this is displayed in the header
  180. LPCSTR pszHeaderSubTitle; //
  181. } PROPSHEETPAGEA_V2, *LPPROPSHEETPAGEA_V2;
  182. typedef const PROPSHEETPAGEA_V2 *LPCPROPSHEETPAGEA_V2;
  183. typedef struct _PROPSHEETPAGEA_V3
  184. {
  185. PROPSHEETPAGEA_V1_FIELDS
  186. LPCSTR pszHeaderTitle; // this is displayed in the header
  187. LPCSTR pszHeaderSubTitle; //
  188. HANDLE hActCtx;
  189. } PROPSHEETPAGEA_V3, *LPPROPSHEETPAGEA_V3;
  190. typedef const PROPSHEETPAGEA_V3 *LPCPROPSHEETPAGEA_V3;
  191. typedef struct _PROPSHEETPAGEW_V1
  192. {
  193. PROPSHEETPAGEW_V1_FIELDS
  194. } PROPSHEETPAGEW_V1, *LPPROPSHEETPAGEW_V1;
  195. typedef const PROPSHEETPAGEW_V1 *LPCPROPSHEETPAGEW_V1;
  196. typedef struct _PROPSHEETPAGEW_V2
  197. {
  198. PROPSHEETPAGEW_V1_FIELDS
  199. LPCWSTR pszHeaderTitle; // this is displayed in the header
  200. LPCWSTR pszHeaderSubTitle; //
  201. } PROPSHEETPAGEW_V2, *LPPROPSHEETPAGEW_V2;
  202. typedef const PROPSHEETPAGEW_V2 *LPCPROPSHEETPAGEW_V2;
  203. typedef struct _PROPSHEETPAGEW_V3
  204. {
  205. PROPSHEETPAGEW_V1_FIELDS
  206. LPCWSTR pszHeaderTitle; // this is displayed in the header
  207. LPCWSTR pszHeaderSubTitle; //
  208. HANDLE hActCtx;
  209. } PROPSHEETPAGEW_V3, *LPPROPSHEETPAGEW_V3;
  210. typedef const PROPSHEETPAGEW_V3 *LPCPROPSHEETPAGEW_V3;
  211. typedef PROPSHEETPAGEA_V3 PROPSHEETPAGEA_LATEST;
  212. typedef PROPSHEETPAGEW_V3 PROPSHEETPAGEW_LATEST;
  213. typedef LPPROPSHEETPAGEA_V3 LPPROPSHEETPAGEA_LATEST;
  214. typedef LPPROPSHEETPAGEW_V3 LPPROPSHEETPAGEW_LATEST;
  215. typedef LPCPROPSHEETPAGEA_V3 LPCPROPSHEETPAGEA_LATEST;
  216. typedef LPCPROPSHEETPAGEW_V3 LPCPROPSHEETPAGEW_LATEST;
  217. #if (_WIN32_WINNT >= 0x0501) || ISOLATION_AWARE_ENABLED
  218. typedef PROPSHEETPAGEA_V3 PROPSHEETPAGEA;
  219. typedef PROPSHEETPAGEW_V3 PROPSHEETPAGEW;
  220. typedef LPPROPSHEETPAGEA_V3 LPPROPSHEETPAGEA;
  221. typedef LPPROPSHEETPAGEW_V3 LPPROPSHEETPAGEW;
  222. typedef LPCPROPSHEETPAGEA_V3 LPCPROPSHEETPAGEA;
  223. typedef LPCPROPSHEETPAGEW_V3 LPCPROPSHEETPAGEW;
  224. #elif (_WIN32_IE >= 0x0400)
  225. typedef PROPSHEETPAGEA_V2 PROPSHEETPAGEA;
  226. typedef PROPSHEETPAGEW_V2 PROPSHEETPAGEW;
  227. typedef LPPROPSHEETPAGEA_V2 LPPROPSHEETPAGEA;
  228. typedef LPPROPSHEETPAGEW_V2 LPPROPSHEETPAGEW;
  229. typedef LPCPROPSHEETPAGEA_V2 LPCPROPSHEETPAGEA;
  230. typedef LPCPROPSHEETPAGEW_V2 LPCPROPSHEETPAGEW;
  231. #else
  232. typedef PROPSHEETPAGEA_V1 PROPSHEETPAGEA;
  233. typedef PROPSHEETPAGEW_V1 PROPSHEETPAGEW;
  234. typedef LPPROPSHEETPAGEA_V1 LPPROPSHEETPAGEA;
  235. typedef LPPROPSHEETPAGEW_V1 LPPROPSHEETPAGEW;
  236. typedef LPCPROPSHEETPAGEA_V1 LPCPROPSHEETPAGEA;
  237. typedef LPCPROPSHEETPAGEW_V1 LPCPROPSHEETPAGEW;
  238. #endif
  239. #if 0 // IEUNIX reserved.
  240. /* Macros for the missing definitions. */
  241. /* Not all, because mostly used in C++. */
  242. #if __STDC__ || defined (NONAMELESSUNION)
  243. # define PSP_pszTemplate(X) ((X).u.pszTemplate)
  244. #else
  245. # define PSP_pszTemplate(X) ((X).pszTemplate)
  246. #endif
  247. #endif
  248. #ifdef UNICODE
  249. #define PROPSHEETPAGE PROPSHEETPAGEW
  250. #define LPPROPSHEETPAGE LPPROPSHEETPAGEW
  251. #define LPCPROPSHEETPAGE LPCPROPSHEETPAGEW
  252. #define PROPSHEETPAGE_V1_SIZE PROPSHEETPAGEW_V1_SIZE
  253. #define PROPSHEETPAGE_V2_SIZE PROPSHEETPAGEW_V2_SIZE
  254. #define PROPSHEETPAGE_V1 PROPSHEETPAGEW_V1
  255. #define LPPROPSHEETPAGE_V1 LPPROPSHEETPAGEW_V1
  256. #define LPCPROPSHEETPAGE_V1 LPCPROPSHEETPAGEW_V1
  257. #define PROPSHEETPAGE_V2 PROPSHEETPAGEW_V2
  258. #define LPPROPSHEETPAGE_V2 LPPROPSHEETPAGEW_V2
  259. #define LPCPROPSHEETPAGE_V2 LPCPROPSHEETPAGEW_V2
  260. #define PROPSHEETPAGE_V3 PROPSHEETPAGEW_V3
  261. #define LPPROPSHEETPAGE_V3 LPPROPSHEETPAGEW_V3
  262. #define LPCPROPSHEETPAGE_V3 LPCPROPSHEETPAGEW_V3
  263. #define PROPSHEETPAGE_LATEST PROPSHEETPAGEW_LATEST
  264. #define LPPROPSHEETPAGE_LATEST LPPROPSHEETPAGEW_LATEST
  265. #define LPCPROPSHEETPAGE_LATEST LPCPROPSHEETPAGEW_LATEST
  266. #else
  267. #define PROPSHEETPAGE PROPSHEETPAGEA
  268. #define LPPROPSHEETPAGE LPPROPSHEETPAGEA
  269. #define LPCPROPSHEETPAGE LPCPROPSHEETPAGEA
  270. #define PROPSHEETPAGE_V1_SIZE PROPSHEETPAGEA_V1_SIZE
  271. #define PROPSHEETPAGE_V2_SIZE PROPSHEETPAGEA_V2_SIZE
  272. #define PROPSHEETPAGE_V1 PROPSHEETPAGEA_V1
  273. #define LPPROPSHEETPAGE_V1 LPPROPSHEETPAGEA_V1
  274. #define LPCPROPSHEETPAGE_V1 LPCPROPSHEETPAGEA_V1
  275. #define PROPSHEETPAGE_V2 PROPSHEETPAGEA_V2
  276. #define LPPROPSHEETPAGE_V2 LPPROPSHEETPAGEA_V2
  277. #define LPCPROPSHEETPAGE_V2 LPCPROPSHEETPAGEA_V2
  278. #define PROPSHEETPAGE_V3 PROPSHEETPAGEA_V3
  279. #define LPPROPSHEETPAGE_V3 LPPROPSHEETPAGEA_V3
  280. #define LPCPROPSHEETPAGE_V3 LPCPROPSHEETPAGEA_V3
  281. #define PROPSHEETPAGE_LATEST PROPSHEETPAGEA_LATEST
  282. #define LPPROPSHEETPAGE_LATEST LPPROPSHEETPAGEA_LATEST
  283. #define LPCPROPSHEETPAGE_LATEST LPCPROPSHEETPAGEA_LATEST
  284. #endif
  285. #define PSH_DEFAULT 0x00000000
  286. #define PSH_PROPTITLE 0x00000001
  287. #define PSH_USEHICON 0x00000002
  288. #define PSH_USEICONID 0x00000004
  289. #define PSH_PROPSHEETPAGE 0x00000008
  290. #define PSH_WIZARDHASFINISH 0x00000010
  291. #define PSH_WIZARD 0x00000020
  292. #define PSH_USEPSTARTPAGE 0x00000040
  293. #define PSH_NOAPPLYNOW 0x00000080
  294. #define PSH_USECALLBACK 0x00000100
  295. #define PSH_HASHELP 0x00000200
  296. #define PSH_MODELESS 0x00000400
  297. #define PSH_RTLREADING 0x00000800
  298. #define PSH_WIZARDCONTEXTHELP 0x00001000
  299. #if (_WIN32_IE >= 0x0400)
  300. //----- New flags for wizard97 -----------
  301. #if (_WIN32_IE < 0x0500)
  302. #define PSH_WIZARD97 0x00002000
  303. #else
  304. #define PSH_WIZARD97 0x01000000
  305. #endif
  306. // 0x00004000 was not used by any previous release
  307. #define PSH_WATERMARK 0x00008000
  308. #define PSH_USEHBMWATERMARK 0x00010000 // user pass in a hbmWatermark instead of pszbmWatermark
  309. #define PSH_USEHPLWATERMARK 0x00020000 //
  310. #define PSH_STRETCHWATERMARK 0x00040000 // stretchwatermark also applies for the header
  311. #define PSH_HEADER 0x00080000
  312. #define PSH_USEHBMHEADER 0x00100000
  313. #define PSH_USEPAGELANG 0x00200000 // use frame dialog template matched to page
  314. //----------------------------------------
  315. #endif
  316. #if (_WIN32_IE >= 0x0500)
  317. //----- New flags for wizard-lite --------
  318. #define PSH_WIZARD_LITE 0x00400000
  319. #define PSH_NOCONTEXTHELP 0x02000000
  320. //----------------------------------------
  321. #endif
  322. typedef int (CALLBACK *PFNPROPSHEETCALLBACK)(HWND, UINT, LPARAM);
  323. #define PROPSHEETHEADERA_V1_SIZE CCSIZEOF_STRUCT(PROPSHEETHEADERA, pfnCallback)
  324. #define PROPSHEETHEADERW_V1_SIZE CCSIZEOF_STRUCT(PROPSHEETHEADERW, pfnCallback)
  325. #define PROPSHEETHEADERA_V2_SIZE CCSIZEOF_STRUCT(PROPSHEETHEADERA, DUMMYUNION5_MEMBER(hbmHeader))
  326. #define PROPSHEETHEADERW_V2_SIZE CCSIZEOF_STRUCT(PROPSHEETHEADERW, DUMMYUNION5_MEMBER(hbmHeader))
  327. typedef struct _PROPSHEETHEADERA
  328. {
  329. DWORD dwSize;
  330. DWORD dwFlags;
  331. HWND hwndParent;
  332. HINSTANCE hInstance;
  333. union
  334. {
  335. HICON hIcon;
  336. LPCSTR pszIcon;
  337. } DUMMYUNIONNAME;
  338. LPCSTR pszCaption;
  339. UINT nPages;
  340. union
  341. {
  342. UINT nStartPage;
  343. LPCSTR pStartPage;
  344. } DUMMYUNIONNAME2;
  345. union
  346. {
  347. LPCPROPSHEETPAGEA ppsp;
  348. HPROPSHEETPAGE *phpage;
  349. } DUMMYUNIONNAME3;
  350. PFNPROPSHEETCALLBACK pfnCallback;
  351. #if (_WIN32_IE >= 0x0400)
  352. union
  353. {
  354. HBITMAP hbmWatermark;
  355. LPCSTR pszbmWatermark;
  356. } DUMMYUNIONNAME4;
  357. HPALETTE hplWatermark;
  358. union
  359. {
  360. HBITMAP hbmHeader; // Header bitmap shares the palette with watermark
  361. LPCSTR pszbmHeader;
  362. } DUMMYUNIONNAME5;
  363. #endif
  364. } PROPSHEETHEADERA, *LPPROPSHEETHEADERA;
  365. typedef const PROPSHEETHEADERA *LPCPROPSHEETHEADERA;
  366. typedef struct _PROPSHEETHEADERW
  367. {
  368. DWORD dwSize;
  369. DWORD dwFlags;
  370. HWND hwndParent;
  371. HINSTANCE hInstance;
  372. union
  373. {
  374. HICON hIcon;
  375. LPCWSTR pszIcon;
  376. } DUMMYUNIONNAME;
  377. LPCWSTR pszCaption;
  378. UINT nPages;
  379. union
  380. {
  381. UINT nStartPage;
  382. LPCWSTR pStartPage;
  383. } DUMMYUNIONNAME2;
  384. union
  385. {
  386. LPCPROPSHEETPAGEW ppsp;
  387. HPROPSHEETPAGE *phpage;
  388. } DUMMYUNIONNAME3;
  389. PFNPROPSHEETCALLBACK pfnCallback;
  390. #if (_WIN32_IE >= 0x0400)
  391. union
  392. {
  393. HBITMAP hbmWatermark;
  394. LPCWSTR pszbmWatermark;
  395. } DUMMYUNIONNAME4;
  396. HPALETTE hplWatermark;
  397. union
  398. {
  399. HBITMAP hbmHeader;
  400. LPCWSTR pszbmHeader;
  401. } DUMMYUNIONNAME5;
  402. #endif
  403. } PROPSHEETHEADERW, *LPPROPSHEETHEADERW;
  404. typedef const PROPSHEETHEADERW *LPCPROPSHEETHEADERW;
  405. #if 0 //IEUNIX reserved.
  406. /* Macros for the missing definitions. */
  407. /* Not all, because mostly used in C++. */
  408. #if __STDC__ || defined (NONAMELESSUNION)
  409. # define PSH_nStartPage(X) ((X).u2.nStartPage)
  410. # define PSH_ppsp(X) ((X).u3.ppsp)
  411. #else
  412. # define PSH_nStartPage(X) ((X).nStartPage)
  413. # define PSH_ppsp(X) ((X).ppsp)
  414. #endif
  415. #endif
  416. #ifdef UNICODE
  417. #define PROPSHEETHEADER PROPSHEETHEADERW
  418. #define LPPROPSHEETHEADER LPPROPSHEETHEADERW
  419. #define LPCPROPSHEETHEADER LPCPROPSHEETHEADERW
  420. #define PROPSHEETHEADER_V1_SIZE PROPSHEETHEADERW_V1_SIZE
  421. #define PROPSHEETHEADER_V2_SIZE PROPSHEETHEADERW_V2_SIZE
  422. #else
  423. #define PROPSHEETHEADER PROPSHEETHEADERA
  424. #define LPPROPSHEETHEADER LPPROPSHEETHEADERA
  425. #define LPCPROPSHEETHEADER LPCPROPSHEETHEADERA
  426. #define PROPSHEETHEADER_V1_SIZE PROPSHEETHEADERA_V1_SIZE
  427. #define PROPSHEETHEADER_V2_SIZE PROPSHEETHEADERA_V2_SIZE
  428. #endif
  429. #define PSCB_INITIALIZED 1
  430. #define PSCB_PRECREATE 2
  431. #if (_WIN32_IE >= 0x560)
  432. // PSCB_BUTTONPRESSED will be sent when the user clicks a button in the
  433. // property dialog (OK, Cancel, Apply, or Close). The message will be sent
  434. // to PROPSHEETHEADER's pfnCallback if the PSH_USECALLBACK flag was specified.
  435. // The LPARAM will be equal to one of the following based on the button pressed:
  436. // This message is only supported on comctl32 v6.
  437. // PSBTN_FINISH (Close), PSBTN_OK, PSBTN_APPLYNOW, or PSBTN_CANCEL
  438. #define PSCB_BUTTONPRESSED 3
  439. #endif // _WIN32_IE >= 0x560
  440. WINCOMMCTRLAPI HPROPSHEETPAGE WINAPI CreatePropertySheetPageA(LPCPROPSHEETPAGEA constPropSheetPagePointer);
  441. WINCOMMCTRLAPI HPROPSHEETPAGE WINAPI CreatePropertySheetPageW(LPCPROPSHEETPAGEW constPropSheetPagePointer);
  442. WINCOMMCTRLAPI BOOL WINAPI DestroyPropertySheetPage(HPROPSHEETPAGE);
  443. WINCOMMCTRLAPI INT_PTR WINAPI PropertySheetA(LPCPROPSHEETHEADERA);
  444. WINCOMMCTRLAPI INT_PTR WINAPI PropertySheetW(LPCPROPSHEETHEADERW);
  445. #ifdef UNICODE
  446. #define CreatePropertySheetPage CreatePropertySheetPageW
  447. #define PropertySheet PropertySheetW
  448. #else
  449. #define CreatePropertySheetPage CreatePropertySheetPageA
  450. #define PropertySheet PropertySheetA
  451. #endif
  452. typedef BOOL (CALLBACK *LPFNADDPROPSHEETPAGE)(HPROPSHEETPAGE, LPARAM);
  453. typedef BOOL (CALLBACK *LPFNADDPROPSHEETPAGES)(LPVOID, LPFNADDPROPSHEETPAGE, LPARAM);
  454. typedef struct _PSHNOTIFY
  455. {
  456. NMHDR hdr;
  457. LPARAM lParam;
  458. } PSHNOTIFY, *LPPSHNOTIFY;
  459. #define PSN_FIRST (0U-200U)
  460. #define PSN_LAST (0U-299U)
  461. #define PSN_SETACTIVE (PSN_FIRST-0)
  462. #define PSN_KILLACTIVE (PSN_FIRST-1)
  463. // #define PSN_VALIDATE (PSN_FIRST-1)
  464. #define PSN_APPLY (PSN_FIRST-2)
  465. #define PSN_RESET (PSN_FIRST-3)
  466. // #define PSN_CANCEL (PSN_FIRST-3)
  467. #define PSN_HELP (PSN_FIRST-5)
  468. #define PSN_WIZBACK (PSN_FIRST-6)
  469. #define PSN_WIZNEXT (PSN_FIRST-7)
  470. #define PSN_WIZFINISH (PSN_FIRST-8)
  471. #define PSN_QUERYCANCEL (PSN_FIRST-9)
  472. #if (_WIN32_IE >= 0x0400)
  473. #define PSN_GETOBJECT (PSN_FIRST-10)
  474. #endif // 0x0400
  475. #if (_WIN32_IE >= 0x0500)
  476. #define PSN_TRANSLATEACCELERATOR (PSN_FIRST-12)
  477. #define PSN_QUERYINITIALFOCUS (PSN_FIRST-13)
  478. #endif // 0x0500
  479. #define PSNRET_NOERROR 0
  480. #define PSNRET_INVALID 1
  481. #define PSNRET_INVALID_NOCHANGEPAGE 2
  482. #define PSNRET_MESSAGEHANDLED 3
  483. #define PSM_SETCURSEL (WM_USER + 101)
  484. #define PropSheet_SetCurSel(hDlg, hpage, index) \
  485. SNDMSG(hDlg, PSM_SETCURSEL, (WPARAM)index, (LPARAM)hpage)
  486. #define PSM_REMOVEPAGE (WM_USER + 102)
  487. #define PropSheet_RemovePage(hDlg, index, hpage) \
  488. SNDMSG(hDlg, PSM_REMOVEPAGE, index, (LPARAM)hpage)
  489. #define PSM_ADDPAGE (WM_USER + 103)
  490. #define PropSheet_AddPage(hDlg, hpage) \
  491. SNDMSG(hDlg, PSM_ADDPAGE, 0, (LPARAM)hpage)
  492. #define PSM_CHANGED (WM_USER + 104)
  493. #define PropSheet_Changed(hDlg, hwnd) \
  494. SNDMSG(hDlg, PSM_CHANGED, (WPARAM)hwnd, 0L)
  495. #define PSM_RESTARTWINDOWS (WM_USER + 105)
  496. #define PropSheet_RestartWindows(hDlg) \
  497. SNDMSG(hDlg, PSM_RESTARTWINDOWS, 0, 0L)
  498. #define PSM_REBOOTSYSTEM (WM_USER + 106)
  499. #define PropSheet_RebootSystem(hDlg) \
  500. SNDMSG(hDlg, PSM_REBOOTSYSTEM, 0, 0L)
  501. #define PSM_CANCELTOCLOSE (WM_USER + 107)
  502. #define PropSheet_CancelToClose(hDlg) \
  503. PostMessage(hDlg, PSM_CANCELTOCLOSE, 0, 0L)
  504. #define PSM_QUERYSIBLINGS (WM_USER + 108)
  505. #define PropSheet_QuerySiblings(hDlg, wParam, lParam) \
  506. SNDMSG(hDlg, PSM_QUERYSIBLINGS, wParam, lParam)
  507. #define PSM_UNCHANGED (WM_USER + 109)
  508. #define PropSheet_UnChanged(hDlg, hwnd) \
  509. SNDMSG(hDlg, PSM_UNCHANGED, (WPARAM)hwnd, 0L)
  510. #define PSM_APPLY (WM_USER + 110)
  511. #define PropSheet_Apply(hDlg) \
  512. SNDMSG(hDlg, PSM_APPLY, 0, 0L)
  513. #define PSM_SETTITLEA (WM_USER + 111)
  514. #define PSM_SETTITLEW (WM_USER + 120)
  515. #ifdef UNICODE
  516. #define PSM_SETTITLE PSM_SETTITLEW
  517. #else
  518. #define PSM_SETTITLE PSM_SETTITLEA
  519. #endif
  520. #define PropSheet_SetTitle(hDlg, wStyle, lpszText)\
  521. SNDMSG(hDlg, PSM_SETTITLE, wStyle, (LPARAM)(LPCTSTR)(lpszText))
  522. #define PSM_SETWIZBUTTONS (WM_USER + 112)
  523. #define PropSheet_SetWizButtons(hDlg, dwFlags) \
  524. PostMessage(hDlg, PSM_SETWIZBUTTONS, 0, (LPARAM)dwFlags)
  525. #define PSWIZB_BACK 0x00000001
  526. #define PSWIZB_NEXT 0x00000002
  527. #define PSWIZB_FINISH 0x00000004
  528. #define PSWIZB_DISABLEDFINISH 0x00000008
  529. #define PSM_PRESSBUTTON (WM_USER + 113)
  530. #define PropSheet_PressButton(hDlg, iButton) \
  531. PostMessage(hDlg, PSM_PRESSBUTTON, (WPARAM)iButton, 0)
  532. #define PSBTN_BACK 0
  533. #define PSBTN_NEXT 1
  534. #define PSBTN_FINISH 2
  535. #define PSBTN_OK 3
  536. #define PSBTN_APPLYNOW 4
  537. #define PSBTN_CANCEL 5
  538. #define PSBTN_HELP 6
  539. #define PSBTN_MAX 6
  540. #define PSM_SETCURSELID (WM_USER + 114)
  541. #define PropSheet_SetCurSelByID(hDlg, id) \
  542. SNDMSG(hDlg, PSM_SETCURSELID, 0, (LPARAM)id)
  543. #define PSM_SETFINISHTEXTA (WM_USER + 115)
  544. #define PSM_SETFINISHTEXTW (WM_USER + 121)
  545. #ifdef UNICODE
  546. #define PSM_SETFINISHTEXT PSM_SETFINISHTEXTW
  547. #else
  548. #define PSM_SETFINISHTEXT PSM_SETFINISHTEXTA
  549. #endif
  550. #define PropSheet_SetFinishText(hDlg, lpszText) \
  551. SNDMSG(hDlg, PSM_SETFINISHTEXT, 0, (LPARAM)lpszText)
  552. #define PSM_GETTABCONTROL (WM_USER + 116)
  553. #define PropSheet_GetTabControl(hDlg) \
  554. (HWND)SNDMSG(hDlg, PSM_GETTABCONTROL, 0, 0)
  555. #define PSM_ISDIALOGMESSAGE (WM_USER + 117)
  556. #define PropSheet_IsDialogMessage(hDlg, pMsg) \
  557. (BOOL)SNDMSG(hDlg, PSM_ISDIALOGMESSAGE, 0, (LPARAM)pMsg)
  558. #define PSM_GETCURRENTPAGEHWND (WM_USER + 118)
  559. #define PropSheet_GetCurrentPageHwnd(hDlg) \
  560. (HWND)SNDMSG(hDlg, PSM_GETCURRENTPAGEHWND, 0, 0L)
  561. #define PSM_INSERTPAGE (WM_USER + 119)
  562. #define PropSheet_InsertPage(hDlg, index, hpage) \
  563. SNDMSG(hDlg, PSM_INSERTPAGE, (WPARAM)(index), (LPARAM)(hpage))
  564. #if (_WIN32_IE >= 0x0500)
  565. #define PSM_SETHEADERTITLEA (WM_USER + 125)
  566. #define PSM_SETHEADERTITLEW (WM_USER + 126)
  567. #ifdef UNICODE
  568. #define PSM_SETHEADERTITLE PSM_SETHEADERTITLEW
  569. #else
  570. #define PSM_SETHEADERTITLE PSM_SETHEADERTITLEA
  571. #endif
  572. #define PropSheet_SetHeaderTitle(hDlg, index, lpszText) \
  573. SNDMSG(hDlg, PSM_SETHEADERTITLE, (WPARAM)(index), (LPARAM)(lpszText))
  574. #define PSM_SETHEADERSUBTITLEA (WM_USER + 127)
  575. #define PSM_SETHEADERSUBTITLEW (WM_USER + 128)
  576. #ifdef UNICODE
  577. #define PSM_SETHEADERSUBTITLE PSM_SETHEADERSUBTITLEW
  578. #else
  579. #define PSM_SETHEADERSUBTITLE PSM_SETHEADERSUBTITLEA
  580. #endif
  581. #define PropSheet_SetHeaderSubTitle(hDlg, index, lpszText) \
  582. SNDMSG(hDlg, PSM_SETHEADERSUBTITLE, (WPARAM)(index), (LPARAM)(lpszText))
  583. #define PSM_HWNDTOINDEX (WM_USER + 129)
  584. #define PropSheet_HwndToIndex(hDlg, hwnd) \
  585. (int)SNDMSG(hDlg, PSM_HWNDTOINDEX, (WPARAM)(hwnd), 0)
  586. #define PSM_INDEXTOHWND (WM_USER + 130)
  587. #define PropSheet_IndexToHwnd(hDlg, i) \
  588. (HWND)SNDMSG(hDlg, PSM_INDEXTOHWND, (WPARAM)(i), 0)
  589. #define PSM_PAGETOINDEX (WM_USER + 131)
  590. #define PropSheet_PageToIndex(hDlg, hpage) \
  591. (int)SNDMSG(hDlg, PSM_PAGETOINDEX, 0, (LPARAM)(hpage))
  592. #define PSM_INDEXTOPAGE (WM_USER + 132)
  593. #define PropSheet_IndexToPage(hDlg, i) \
  594. (HPROPSHEETPAGE)SNDMSG(hDlg, PSM_INDEXTOPAGE, (WPARAM)(i), 0)
  595. #define PSM_IDTOINDEX (WM_USER + 133)
  596. #define PropSheet_IdToIndex(hDlg, id) \
  597. (int)SNDMSG(hDlg, PSM_IDTOINDEX, 0, (LPARAM)(id))
  598. #define PSM_INDEXTOID (WM_USER + 134)
  599. #define PropSheet_IndexToId(hDlg, i) \
  600. SNDMSG(hDlg, PSM_INDEXTOID, (WPARAM)(i), 0)
  601. #define PSM_GETRESULT (WM_USER + 135)
  602. #define PropSheet_GetResult(hDlg) \
  603. SNDMSG(hDlg, PSM_GETRESULT, 0, 0)
  604. #define PSM_RECALCPAGESIZES (WM_USER + 136)
  605. #define PropSheet_RecalcPageSizes(hDlg) \
  606. SNDMSG(hDlg, PSM_RECALCPAGESIZES, 0, 0)
  607. #endif // 0x0500
  608. #define ID_PSRESTARTWINDOWS 0x2
  609. #define ID_PSREBOOTSYSTEM (ID_PSRESTARTWINDOWS | 0x1)
  610. #define WIZ_CXDLG 276
  611. #define WIZ_CYDLG 140
  612. #define WIZ_CXBMP 80
  613. #define WIZ_BODYX 92
  614. #define WIZ_BODYCX 184
  615. #define PROP_SM_CXDLG 212
  616. #define PROP_SM_CYDLG 188
  617. #define PROP_MED_CXDLG 227
  618. #define PROP_MED_CYDLG 215
  619. #define PROP_LG_CXDLG 252
  620. #define PROP_LG_CYDLG 218
  621. #if !defined(RC_INVOKED) /* RC complains about long symbols in #ifs */
  622. #if defined(ISOLATION_AWARE_ENABLED) && (ISOLATION_AWARE_ENABLED != 0)
  623. #if !defined(ISOLATION_AWARE_USE_STATIC_LIBRARY)
  624. #define ISOLATION_AWARE_USE_STATIC_LIBRARY 0
  625. #endif
  626. #if !defined(ISOLATION_AWARE_BUILD_STATIC_LIBRARY)
  627. #define ISOLATION_AWARE_BUILD_STATIC_LIBRARY 0
  628. #endif
  629. #if !defined(ISOLATION_AWARE_INLINE)
  630. #if ISOLATION_AWARE_BUILD_STATIC_LIBRARY
  631. #define ISOLATION_AWARE_INLINE /* nothing */
  632. #else
  633. #if defined(__cplusplus)
  634. #define ISOLATION_AWARE_INLINE inline
  635. #else
  636. #define ISOLATION_AWARE_INLINE __inline
  637. #endif
  638. #endif
  639. #endif
  640. #if !ISOLATION_AWARE_USE_STATIC_LIBRARY
  641. FARPROC WINAPI PrshtIsolationAwarePrivatetRgCebPnQQeRff_pbZPgYQP_QYY(LPCSTR pszProcName);
  642. #ifndef CCSIZEOF_STRUCT
  643. #define CCSIZEOF_STRUCT(structname, member) (((int)((LPBYTE)(&((structname*)0)->member) - ((LPBYTE)((structname*)0)))) + sizeof(((structname*)0)->member))
  644. #endif
  645. #endif /* ISOLATION_AWARE_USE_STATIC_LIBRARY */
  646. HPROPSHEETPAGE WINAPI IsolationAwareCreatePropertySheetPageA(LPCPROPSHEETPAGEA constPropSheetPagePointer);
  647. HPROPSHEETPAGE WINAPI IsolationAwareCreatePropertySheetPageW(LPCPROPSHEETPAGEW constPropSheetPagePointer);
  648. BOOL WINAPI IsolationAwareDestroyPropertySheetPage(HPROPSHEETPAGE unnamed1);
  649. INT_PTR WINAPI IsolationAwarePropertySheetA(LPCPROPSHEETHEADERA unnamed1);
  650. INT_PTR WINAPI IsolationAwarePropertySheetW(LPCPROPSHEETHEADERW unnamed1);
  651. #if defined(UNICODE)
  652. #define IsolationAwareCreatePropertySheetPage IsolationAwareCreatePropertySheetPageW
  653. #define IsolationAwarePropertySheet IsolationAwarePropertySheetW
  654. #else /* UNICODE */
  655. #define IsolationAwareCreatePropertySheetPage IsolationAwareCreatePropertySheetPageA
  656. #define IsolationAwarePropertySheet IsolationAwarePropertySheetA
  657. #endif /* UNICODE */
  658. #if !ISOLATION_AWARE_USE_STATIC_LIBRARY
  659. ISOLATION_AWARE_INLINE HPROPSHEETPAGE WINAPI IsolationAwareCreatePropertySheetPageA(LPCPROPSHEETPAGEA constPropSheetPagePointer)
  660. {
  661. HPROPSHEETPAGE result = NULL;
  662. typedef HPROPSHEETPAGE (WINAPI* PFN)(LPCPROPSHEETPAGEA constPropSheetPagePointer);
  663. static PFN s_pfn;
  664. const LPPROPSHEETPAGEA_LATEST latestPropSheetPagePointer = (LPPROPSHEETPAGEA_LATEST)constPropSheetPagePointer;
  665. ULONG_PTR ulpCookie = 0;
  666. const BOOL fActivateActCtxSuccess = IsolationAwarePrivateT_SqbjaYRiRY || IsolationAwarePrivatenPgViNgRzlnPgpgk(&ulpCookie);
  667. if (!fActivateActCtxSuccess)
  668. return result;
  669. __try
  670. {
  671. if (s_pfn == NULL)
  672. {
  673. s_pfn = (PFN)PrshtIsolationAwarePrivatetRgCebPnQQeRff_pbZPgYQP_QYY("CreatePropertySheetPageA");
  674. if (s_pfn == NULL)
  675. __leave;
  676. }
  677. if (IsolationAwarePrivateT_SqbjaYRiRY)
  678. {
  679. if ((latestPropSheetPagePointer->dwFlags & PSP_USEFUSIONCONTEXT) != 0)
  680. {
  681. latestPropSheetPagePointer->dwFlags &= ~PSP_USEFUSIONCONTEXT;
  682. }
  683. }
  684. else if (( latestPropSheetPagePointer->dwFlags & PSP_USEFUSIONCONTEXT) == 0
  685. && latestPropSheetPagePointer->dwSize >= CCSIZEOF_STRUCT(PROPSHEETPAGEA_V3, hActCtx)
  686. )
  687. {
  688. latestPropSheetPagePointer->dwFlags |= PSP_USEFUSIONCONTEXT;
  689. latestPropSheetPagePointer->hActCtx = WinbaseIsolationAwarePrivateT_UnPgpgk;
  690. }
  691. result = s_pfn(constPropSheetPagePointer);
  692. }
  693. __finally
  694. {
  695. if (!IsolationAwarePrivateT_SqbjaYRiRY)
  696. {
  697. const BOOL fPreserveLastError = (result == NULL);
  698. const DWORD dwLastError = fPreserveLastError ? GetLastError() : NO_ERROR;
  699. (void)IsolationAwareDeactivateActCtx(0, ulpCookie);
  700. if (fPreserveLastError)
  701. SetLastError(dwLastError);
  702. }
  703. }
  704. return result;
  705. }
  706. ISOLATION_AWARE_INLINE HPROPSHEETPAGE WINAPI IsolationAwareCreatePropertySheetPageW(LPCPROPSHEETPAGEW constPropSheetPagePointer)
  707. {
  708. HPROPSHEETPAGE result = NULL;
  709. typedef HPROPSHEETPAGE (WINAPI* PFN)(LPCPROPSHEETPAGEW constPropSheetPagePointer);
  710. static PFN s_pfn;
  711. const LPPROPSHEETPAGEW_LATEST latestPropSheetPagePointer = (LPPROPSHEETPAGEW_LATEST)constPropSheetPagePointer;
  712. ULONG_PTR ulpCookie = 0;
  713. const BOOL fActivateActCtxSuccess = IsolationAwarePrivateT_SqbjaYRiRY || IsolationAwarePrivatenPgViNgRzlnPgpgk(&ulpCookie);
  714. if (!fActivateActCtxSuccess)
  715. return result;
  716. __try
  717. {
  718. if (s_pfn == NULL)
  719. {
  720. s_pfn = (PFN)PrshtIsolationAwarePrivatetRgCebPnQQeRff_pbZPgYQP_QYY("CreatePropertySheetPageW");
  721. if (s_pfn == NULL)
  722. __leave;
  723. }
  724. if (IsolationAwarePrivateT_SqbjaYRiRY)
  725. {
  726. if ((latestPropSheetPagePointer->dwFlags & PSP_USEFUSIONCONTEXT) != 0)
  727. {
  728. latestPropSheetPagePointer->dwFlags &= ~PSP_USEFUSIONCONTEXT;
  729. }
  730. }
  731. else if (( latestPropSheetPagePointer->dwFlags & PSP_USEFUSIONCONTEXT) == 0
  732. && latestPropSheetPagePointer->dwSize >= CCSIZEOF_STRUCT(PROPSHEETPAGEW_V3, hActCtx)
  733. )
  734. {
  735. latestPropSheetPagePointer->dwFlags |= PSP_USEFUSIONCONTEXT;
  736. latestPropSheetPagePointer->hActCtx = WinbaseIsolationAwarePrivateT_UnPgpgk;
  737. }
  738. result = s_pfn(constPropSheetPagePointer);
  739. }
  740. __finally
  741. {
  742. if (!IsolationAwarePrivateT_SqbjaYRiRY)
  743. {
  744. const BOOL fPreserveLastError = (result == NULL);
  745. const DWORD dwLastError = fPreserveLastError ? GetLastError() : NO_ERROR;
  746. (void)IsolationAwareDeactivateActCtx(0, ulpCookie);
  747. if (fPreserveLastError)
  748. SetLastError(dwLastError);
  749. }
  750. }
  751. return result;
  752. }
  753. ISOLATION_AWARE_INLINE BOOL WINAPI IsolationAwareDestroyPropertySheetPage(HPROPSHEETPAGE unnamed1)
  754. {
  755. BOOL fResult = FALSE;
  756. typedef BOOL (WINAPI* PFN)(HPROPSHEETPAGE unnamed1);
  757. static PFN s_pfn;
  758. ULONG_PTR ulpCookie = 0;
  759. const BOOL fActivateActCtxSuccess = IsolationAwarePrivateT_SqbjaYRiRY || IsolationAwarePrivatenPgViNgRzlnPgpgk(&ulpCookie);
  760. if (!fActivateActCtxSuccess)
  761. return fResult;
  762. __try
  763. {
  764. if (s_pfn == NULL)
  765. {
  766. s_pfn = (PFN)PrshtIsolationAwarePrivatetRgCebPnQQeRff_pbZPgYQP_QYY("DestroyPropertySheetPage");
  767. if (s_pfn == NULL)
  768. __leave;
  769. }
  770. fResult = s_pfn(unnamed1);
  771. }
  772. __finally
  773. {
  774. if (!IsolationAwarePrivateT_SqbjaYRiRY)
  775. {
  776. const BOOL fPreserveLastError = (fResult == FALSE);
  777. const DWORD dwLastError = fPreserveLastError ? GetLastError() : NO_ERROR;
  778. (void)IsolationAwareDeactivateActCtx(0, ulpCookie);
  779. if (fPreserveLastError)
  780. SetLastError(dwLastError);
  781. }
  782. }
  783. return fResult;
  784. }
  785. ISOLATION_AWARE_INLINE INT_PTR WINAPI IsolationAwarePropertySheetA(LPCPROPSHEETHEADERA unnamed1)
  786. {
  787. INT_PTR nResult = -1;
  788. typedef INT_PTR (WINAPI* PFN)(LPCPROPSHEETHEADERA unnamed1);
  789. static PFN s_pfn;
  790. ULONG_PTR ulpCookie = 0;
  791. const BOOL fActivateActCtxSuccess = IsolationAwarePrivateT_SqbjaYRiRY || IsolationAwarePrivatenPgViNgRzlnPgpgk(&ulpCookie);
  792. if (!fActivateActCtxSuccess)
  793. return nResult;
  794. __try
  795. {
  796. if (s_pfn == NULL)
  797. {
  798. s_pfn = (PFN)PrshtIsolationAwarePrivatetRgCebPnQQeRff_pbZPgYQP_QYY("PropertySheetA");
  799. if (s_pfn == NULL)
  800. __leave;
  801. }
  802. nResult = s_pfn(unnamed1);
  803. }
  804. __finally
  805. {
  806. if (!IsolationAwarePrivateT_SqbjaYRiRY)
  807. {
  808. const BOOL fPreserveLastError = (nResult == -1);
  809. const DWORD dwLastError = fPreserveLastError ? GetLastError() : NO_ERROR;
  810. (void)IsolationAwareDeactivateActCtx(0, ulpCookie);
  811. if (fPreserveLastError)
  812. SetLastError(dwLastError);
  813. }
  814. }
  815. return nResult;
  816. }
  817. ISOLATION_AWARE_INLINE INT_PTR WINAPI IsolationAwarePropertySheetW(LPCPROPSHEETHEADERW unnamed1)
  818. {
  819. INT_PTR nResult = -1;
  820. typedef INT_PTR (WINAPI* PFN)(LPCPROPSHEETHEADERW unnamed1);
  821. static PFN s_pfn;
  822. ULONG_PTR ulpCookie = 0;
  823. const BOOL fActivateActCtxSuccess = IsolationAwarePrivateT_SqbjaYRiRY || IsolationAwarePrivatenPgViNgRzlnPgpgk(&ulpCookie);
  824. if (!fActivateActCtxSuccess)
  825. return nResult;
  826. __try
  827. {
  828. if (s_pfn == NULL)
  829. {
  830. s_pfn = (PFN)PrshtIsolationAwarePrivatetRgCebPnQQeRff_pbZPgYQP_QYY("PropertySheetW");
  831. if (s_pfn == NULL)
  832. __leave;
  833. }
  834. nResult = s_pfn(unnamed1);
  835. }
  836. __finally
  837. {
  838. if (!IsolationAwarePrivateT_SqbjaYRiRY)
  839. {
  840. const BOOL fPreserveLastError = (nResult == -1);
  841. const DWORD dwLastError = fPreserveLastError ? GetLastError() : NO_ERROR;
  842. (void)IsolationAwareDeactivateActCtx(0, ulpCookie);
  843. if (fPreserveLastError)
  844. SetLastError(dwLastError);
  845. }
  846. }
  847. return nResult;
  848. }
  849. ISOLATION_AWARE_INLINE FARPROC WINAPI PrshtIsolationAwarePrivatetRgCebPnQQeRff_pbZPgYQP_QYY(LPCSTR pszProcName)
  850. /* This function is shared by the other stubs in this header. */
  851. {
  852. FARPROC proc = NULL;
  853. static HMODULE s_module;
  854. BOOL fActivateActCtxSuccess = FALSE;
  855. ULONG_PTR ulpCookie = 0;
  856. const static IsolationAwarePrivatepBAFGnAG_zBqHyr_vAsB
  857. c = { IsolationAwarePrivatezlybNQyVOeNeln, IsolationAwarePrivatezlybNQyVOeNelJ, "Comctl32.dll", L"Comctl32.dll" };
  858. static IsolationAwarePrivatezHGnoyr_zBqHyr_vAsB m;
  859. __try
  860. {
  861. if (!IsolationAwarePrivateT_SqbjaYRiRY)
  862. {
  863. fActivateActCtxSuccess = IsolationAwarePrivatenPgViNgRzlnPgpgk(&ulpCookie);
  864. if (!fActivateActCtxSuccess)
  865. __leave;
  866. }
  867. proc = IsolationAwarePrivatezltRgCebPnQQeRff(&c, &m, pszProcName);
  868. }
  869. __finally
  870. {
  871. if (!IsolationAwarePrivateT_SqbjaYRiRY && fActivateActCtxSuccess)
  872. {
  873. const DWORD dwLastError = (proc == NULL) ? GetLastError() : NO_ERROR;
  874. (void)IsolationAwareDeactivateActCtx(0, ulpCookie);
  875. if (proc == NULL)
  876. SetLastError(dwLastError);
  877. }
  878. }
  879. return proc;
  880. }
  881. #endif /* ISOLATION_AWARE_USE_STATIC_LIBRARY */
  882. #define CreatePropertySheetPageA IsolationAwareCreatePropertySheetPageA
  883. #define CreatePropertySheetPageW IsolationAwareCreatePropertySheetPageW
  884. #define DestroyPropertySheetPage IsolationAwareDestroyPropertySheetPage
  885. #define PropertySheetA IsolationAwarePropertySheetA
  886. #define PropertySheetW IsolationAwarePropertySheetW
  887. #endif /* ISOLATION_AWARE_ENABLED */
  888. #endif /* RC */
  889. #ifdef __cplusplus
  890. }
  891. #endif
  892. #include <poppack.h>
  893. #endif // _PRSHT_H_