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.

1131 lines
19 KiB

  1. #include "shellpch.h"
  2. #pragma hdrstop
  3. #define _UXTHEME_
  4. #include <uxtheme.h>
  5. #include <uxthemep.h>
  6. #undef THEMEAPI_
  7. #define THEMEAPI_(type) type STDAPICALLTYPE
  8. #undef THEMEAPI
  9. #define THEMEAPI HRESULT STDAPICALLTYPE
  10. static
  11. HRESULT
  12. WINAPI
  13. ApplyTheme(
  14. HTHEMEFILE hThemeFile,
  15. DWORD dwApplyFlags,
  16. HWND hwndTarget
  17. )
  18. {
  19. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  20. }
  21. static
  22. HRESULT
  23. WINAPI
  24. CloseThemeData(
  25. HTHEME hTheme
  26. )
  27. {
  28. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  29. }
  30. static
  31. HRESULT
  32. WINAPI
  33. CloseThemeFile(
  34. HTHEMEFILE hThemeFile
  35. )
  36. {
  37. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  38. }
  39. static
  40. HRESULT
  41. WINAPI
  42. DrawNCPreview(
  43. HDC hdc,
  44. DWORD dwFlags,
  45. LPRECT prc,
  46. LPCWSTR pszVSPath,
  47. LPCWSTR pszVSColor,
  48. LPCWSTR pszVSSize,
  49. NONCLIENTMETRICS* pncm,
  50. COLORREF* prgb
  51. )
  52. {
  53. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  54. }
  55. static
  56. HRESULT
  57. WINAPI
  58. EnumThemes(
  59. LPCWSTR pszThemeRoot,
  60. THEMEENUMPROC lpEnumFunc,
  61. LPARAM lParam
  62. )
  63. {
  64. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  65. }
  66. static
  67. HRESULT
  68. WINAPI
  69. EnumThemeColors(
  70. LPCWSTR pszThemeName,
  71. LPCWSTR pszSizeName,
  72. DWORD dwColorIndex,
  73. THEMENAMEINFO *ptn
  74. )
  75. {
  76. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  77. }
  78. static
  79. HRESULT
  80. WINAPI
  81. EnumThemeSizes(
  82. LPCWSTR pszThemeName,
  83. LPCWSTR pszColorScheme,
  84. DWORD dwSizeIndex,
  85. THEMENAMEINFO *ptn
  86. )
  87. {
  88. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  89. }
  90. static
  91. HRESULT
  92. WINAPI
  93. GetCurrentThemeName(
  94. LPWSTR pszNameBuff,
  95. int cchMaxNameChars,
  96. LPWSTR pszColorBuff,
  97. int cchMaxColorChars,
  98. LPWSTR pszSizeBuff,
  99. int cchMaxSizeChars
  100. )
  101. {
  102. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  103. }
  104. static
  105. HRESULT
  106. WINAPI
  107. EnableTheming(
  108. BOOL fEnable
  109. )
  110. {
  111. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  112. }
  113. static
  114. HRESULT
  115. WINAPI
  116. GetThemeDefaults(
  117. LPCWSTR pszThemeName,
  118. LPWSTR pszDefaultColor,
  119. int cchMaxColorChars,
  120. LPWSTR pszDefaultSize,
  121. int cchMaxSizeChars
  122. )
  123. {
  124. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  125. }
  126. static
  127. HRESULT
  128. WINAPI
  129. GetThemeDocumentationProperty(
  130. LPCWSTR pszThemeName,
  131. LPCWSTR pszPropertyName,
  132. LPWSTR pszValueBuff,
  133. int cchMaxValChars
  134. )
  135. {
  136. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  137. }
  138. static
  139. HRESULT
  140. WINAPI
  141. GetThemeSysString(
  142. HTHEME hTheme,
  143. int iStringId,
  144. LPWSTR pszStringBuff,
  145. int cchMaxStringChars
  146. )
  147. {
  148. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  149. }
  150. static
  151. COLORREF
  152. WINAPI
  153. GetThemeSysColor(
  154. HTHEME hTheme,
  155. int iColorId
  156. )
  157. {
  158. return 0x000000;
  159. }
  160. static
  161. HBRUSH
  162. WINAPI
  163. GetThemeSysColorBrush(
  164. HTHEME hTheme,
  165. int iColorId
  166. )
  167. {
  168. return NULL;
  169. }
  170. static
  171. HRESULT
  172. WINAPI
  173. GetThemeSysInt(
  174. HTHEME hTheme,
  175. int iIntId,
  176. int *piValue
  177. )
  178. {
  179. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  180. }
  181. static
  182. BOOL
  183. WINAPI
  184. GetThemeSysBool(
  185. HTHEME hTheme,
  186. int iBoolId
  187. )
  188. {
  189. return FALSE;
  190. }
  191. static
  192. int
  193. WINAPI
  194. GetThemeSysSize(
  195. HTHEME hTheme,
  196. int iSizeId
  197. )
  198. {
  199. return 0;
  200. }
  201. static
  202. int
  203. WINAPI
  204. GetThemeSysSize96(
  205. HTHEME hTheme,
  206. int iSizeId
  207. )
  208. {
  209. return 0;
  210. }
  211. static
  212. HRESULT
  213. WINAPI
  214. GetThemeSysFont(
  215. HTHEME hTheme,
  216. int iFontId,
  217. OUT LOGFONT *plf
  218. )
  219. {
  220. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  221. }
  222. static
  223. HRESULT
  224. WINAPI
  225. GetThemeSysFont96(
  226. HTHEME hTheme,
  227. int iFontId,
  228. OUT LOGFONT *plf
  229. )
  230. {
  231. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  232. }
  233. static
  234. HRESULT
  235. WINAPI
  236. OpenThemeFile(
  237. LPCWSTR pszThemePath,
  238. OPTIONAL LPCWSTR pszColorParam,
  239. OPTIONAL LPCWSTR pszSizeParam,
  240. OUT HTHEMEFILE *phThemeFile,
  241. BOOL fGlobalTheme
  242. )
  243. {
  244. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  245. }
  246. static
  247. HRESULT
  248. WINAPI
  249. GetThemeParseErrorInfo(
  250. PARSE_ERROR_INFO *pInfo
  251. )
  252. {
  253. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  254. }
  255. static
  256. HRESULT
  257. WINAPI
  258. OpenThemeFileFromData(
  259. HTHEME hTheme,
  260. HTHEMEFILE *phThemeFile
  261. )
  262. {
  263. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  264. }
  265. static
  266. HTHEME
  267. WINAPI
  268. OpenThemeDataFromFile(
  269. HTHEMEFILE hLoadedThemeFile,
  270. HWND hwnd,
  271. LPCWSTR pszClassList,
  272. BOOL fClient
  273. )
  274. {
  275. return NULL;
  276. }
  277. static
  278. DWORD
  279. WINAPI
  280. QueryThemeServices(
  281. void
  282. )
  283. {
  284. return 0;
  285. }
  286. static
  287. HRESULT
  288. WINAPI
  289. RegisterDefaultTheme(
  290. LPCWSTR pszFileName,
  291. BOOL fOverride
  292. )
  293. {
  294. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  295. }
  296. static
  297. HRESULT
  298. WINAPI
  299. SetWindowTheme(
  300. HWND hwnd,
  301. LPCWSTR pszSubAppName,
  302. LPCWSTR pszSubIdList
  303. )
  304. {
  305. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  306. }
  307. static
  308. BOOL
  309. WINAPI
  310. IsThemeActive(
  311. void
  312. )
  313. {
  314. return FALSE;
  315. }
  316. // These functions are exported for the use of the server. When the server
  317. // is collapsed in themesrv.dll these should be removed because they will
  318. // not be used and should not be exposed.
  319. static
  320. void*
  321. WINAPI
  322. SessionAllocate(
  323. HANDLE hProcess,
  324. DWORD dwServerChangeNumber,
  325. void *pfnRegister,
  326. void *pfnUnregister,
  327. void *pfnClearStockObject,
  328. DWORD dwStackSizeReserve,
  329. DWORD dwStackSizeCommit
  330. )
  331. {
  332. return NULL;
  333. }
  334. static
  335. void
  336. WINAPI
  337. SessionFree(
  338. void *pvContext
  339. )
  340. {
  341. }
  342. static
  343. HRESULT
  344. WINAPI
  345. ThemeHooksOn(
  346. void *pvContext
  347. )
  348. {
  349. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  350. }
  351. static
  352. HRESULT
  353. WINAPI
  354. ThemeHooksOff(
  355. void *pvContext
  356. )
  357. {
  358. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  359. }
  360. static
  361. BOOL
  362. WINAPI
  363. AreThemeHooksActive(
  364. void *pvContext
  365. )
  366. {
  367. return FALSE;
  368. }
  369. static
  370. int
  371. WINAPI
  372. GetCurrentChangeNumber(
  373. void *pvContext
  374. )
  375. {
  376. return -1;
  377. }
  378. static
  379. int
  380. WINAPI
  381. GetNewChangeNumber(
  382. void *pvContext
  383. )
  384. {
  385. return -1;
  386. }
  387. static
  388. HRESULT
  389. WINAPI
  390. SetGlobalTheme(
  391. void *pvContext,
  392. HANDLE hSection
  393. )
  394. {
  395. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  396. }
  397. static
  398. void
  399. WINAPI
  400. MarkSection(
  401. HANDLE hSection,
  402. DWORD dwAdd,
  403. DWORD dwRemove
  404. )
  405. {
  406. }
  407. static
  408. HRESULT
  409. WINAPI
  410. SetSystemVisualStyle(
  411. LPCWSTR pszVisualStylesFile,
  412. LPCWSTR pszColorScheme,
  413. LPCWSTR pszSize,
  414. DWORD dwApplyFlags )
  415. {
  416. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  417. }
  418. static
  419. HRESULT
  420. WINAPI
  421. ServiceClearStockObjects(
  422. PVOID pvContext,
  423. HANDLE hSection )
  424. {
  425. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  426. }
  427. static
  428. HRESULT
  429. WINAPI
  430. GetGlobalTheme(
  431. void *pvContext,
  432. HANDLE *phSection
  433. )
  434. {
  435. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  436. }
  437. static
  438. HRESULT
  439. WINAPI
  440. CheckThemeSignature(
  441. LPCWSTR pszName
  442. )
  443. {
  444. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  445. }
  446. static
  447. HRESULT
  448. WINAPI
  449. LoadTheme(
  450. void *pvContext,
  451. HANDLE hSection,
  452. HANDLE *phSection,
  453. LPCWSTR pszName,
  454. LPCWSTR pszColor,
  455. LPCWSTR pszSize,
  456. DWORD dwLoadFlags
  457. )
  458. {
  459. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  460. }
  461. static
  462. HRESULT
  463. WINAPI
  464. InitUserTheme(
  465. BOOL fPolicyCheckOnly
  466. )
  467. {
  468. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  469. }
  470. static
  471. HRESULT
  472. WINAPI
  473. InitUserRegistry(
  474. void
  475. )
  476. {
  477. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  478. }
  479. static
  480. HRESULT
  481. WINAPI
  482. ReestablishServerConnection(
  483. void
  484. )
  485. {
  486. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  487. }
  488. static
  489. void
  490. WINAPI
  491. ThemeHooksInstall(
  492. void *pvContext
  493. )
  494. {
  495. }
  496. static
  497. void
  498. WINAPI
  499. ThemeHooksRemove(
  500. void *pvContext
  501. )
  502. {
  503. }
  504. static
  505. void
  506. WINAPI
  507. ServerClearStockObjects(
  508. void *pvContext
  509. )
  510. {
  511. }
  512. static
  513. int
  514. WINAPI
  515. ClassicGetSystemMetrics(
  516. int iMetric
  517. )
  518. {
  519. return 0;
  520. }
  521. static
  522. BOOL
  523. WINAPI
  524. ClassicSystemParametersInfoA(
  525. UINT uiAction,
  526. UINT uiParam,
  527. PVOID pvParam,
  528. UINT fWinIni
  529. )
  530. {
  531. return FALSE;
  532. }
  533. static
  534. BOOL
  535. WINAPI
  536. ClassicSystemParametersInfoW(
  537. UINT uiAction,
  538. UINT uiParam,
  539. PVOID pvParam,
  540. UINT fWinIni
  541. )
  542. {
  543. return FALSE;
  544. }
  545. static
  546. HRESULT
  547. WINAPI
  548. GetThemeInt(
  549. HTHEME hTheme,
  550. int iPartId,
  551. int iStateId,
  552. int iPropId,
  553. OUT int *piVal
  554. )
  555. {
  556. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  557. }
  558. static
  559. HRESULT
  560. WINAPI
  561. GetThemeTextMetrics(
  562. HTHEME hTheme,
  563. HDC hdc,
  564. int iPartId,
  565. int iStateId,
  566. OUT TEXTMETRIC* ptm
  567. )
  568. {
  569. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  570. }
  571. static
  572. HRESULT
  573. WINAPI
  574. GetThemeFont(
  575. HTHEME hTheme,
  576. OPTIONAL HDC hdc,
  577. int iPartId,
  578. int iStateId,
  579. int iPropId,
  580. OUT LOGFONT *pFont
  581. )
  582. {
  583. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  584. }
  585. static
  586. HRESULT
  587. WINAPI
  588. GetThemeMetric(
  589. HTHEME hTheme,
  590. OPTIONAL HDC hdc,
  591. int iPartId,
  592. int iStateId,
  593. int iPropId,
  594. OUT int *piVal
  595. )
  596. {
  597. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  598. }
  599. static
  600. BOOL
  601. WINAPI
  602. IsThemeBackgroundPartiallyTransparent(
  603. HTHEME hTheme,
  604. int iPartId,
  605. int iStateId
  606. )
  607. {
  608. return FALSE;
  609. }
  610. static
  611. BOOL
  612. WINAPI
  613. IsThemePartDefined(
  614. HTHEME hTheme,
  615. int iPartId,
  616. int iStateId
  617. )
  618. {
  619. return FALSE;
  620. }
  621. static
  622. HRESULT
  623. WINAPI
  624. GetThemeMargins(
  625. HTHEME hTheme,
  626. OPTIONAL HDC hdc,
  627. int iPartId,
  628. int iStateId,
  629. int iPropId,
  630. OPTIONAL RECT *prc,
  631. OUT MARGINS *pMargins
  632. )
  633. {
  634. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  635. }
  636. static
  637. HRESULT
  638. WINAPI
  639. GetThemePartSize(
  640. HTHEME hTheme,
  641. HDC hdc,
  642. int iPartId,
  643. int iStateId,
  644. OPTIONAL RECT *prc,
  645. enum THEMESIZE eSize,
  646. OUT SIZE *psz
  647. )
  648. {
  649. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  650. }
  651. static
  652. HRESULT
  653. WINAPI
  654. DrawThemeEdge(
  655. HTHEME hTheme,
  656. HDC hdc,
  657. int iPartId,
  658. int iStateId,
  659. const RECT *pDestRect,
  660. UINT uEdge,
  661. UINT uFlags,
  662. OPTIONAL OUT RECT *pContentRect
  663. )
  664. {
  665. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  666. }
  667. static
  668. HRESULT
  669. WINAPI
  670. HitTestThemeBackground(
  671. HTHEME hTheme,
  672. OPTIONAL HDC hdc,
  673. int iPartId,
  674. int iStateId,
  675. DWORD dwOptions,
  676. const RECT *pRect,
  677. OPTIONAL HRGN hrgn,
  678. POINT ptTest,
  679. OUT WORD *pwHitTestCode
  680. )
  681. {
  682. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  683. }
  684. static
  685. HRESULT
  686. WINAPI
  687. GetThemeBackgroundExtent(
  688. HTHEME hTheme,
  689. OPTIONAL HDC hdc,
  690. int iPartId,
  691. int iStateId,
  692. const RECT *pContentRect,
  693. OUT RECT *pExtentRect
  694. )
  695. {
  696. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  697. }
  698. static
  699. HRESULT
  700. WINAPI
  701. GetThemeBackgroundRegion(
  702. HTHEME hTheme,
  703. OPTIONAL HDC hdc,
  704. int iPartId,
  705. int iStateId,
  706. const RECT *pRect,
  707. OUT HRGN *pRegion
  708. )
  709. {
  710. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  711. }
  712. static
  713. HRESULT
  714. WINAPI
  715. GetThemeTextExtent(
  716. HTHEME hTheme,
  717. HDC hdc,
  718. int iPartId,
  719. int iStateId,
  720. LPCWSTR pszText,
  721. int iCharCount,
  722. DWORD dwTextFlags,
  723. OPTIONAL const RECT *pBoundingRect,
  724. OUT RECT *pExtentRect
  725. )
  726. {
  727. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  728. }
  729. static
  730. HTHEME
  731. WINAPI
  732. OpenThemeData(
  733. HWND hwnd,
  734. LPCWSTR pszClassIdList
  735. )
  736. {
  737. return NULL;
  738. }
  739. static
  740. HRESULT
  741. WINAPI
  742. DrawThemeBackground(
  743. HTHEME hTheme,
  744. HDC hdc,
  745. int iPartId,
  746. int iStateId,
  747. const RECT *pRect,
  748. OPTIONAL const RECT *pClipRect
  749. )
  750. {
  751. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  752. }
  753. static
  754. HRESULT
  755. WINAPI
  756. DrawThemeParentBackground(
  757. HWND hwnd,
  758. HDC hdc,
  759. RECT* prc
  760. )
  761. {
  762. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  763. }
  764. static
  765. HRESULT
  766. WINAPI
  767. RefreshThemeForTS(
  768. )
  769. {
  770. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  771. }
  772. static HRESULT WINAPI DrawThemeIcon(HTHEME hTheme, HDC hdc, int iPartId,
  773. int iStateId, const RECT *pRect, HIMAGELIST himl, int iImageIndex)
  774. {
  775. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  776. }
  777. static
  778. HRESULT
  779. WINAPI
  780. GetThemeBackgroundContentRect(
  781. HTHEME hTheme,
  782. OPTIONAL HDC hdc,
  783. int iPartId,
  784. int iStateId,
  785. const RECT *pBoundingRect,
  786. OUT RECT *pContentRect
  787. )
  788. {
  789. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  790. }
  791. static
  792. HRESULT
  793. WINAPI
  794. GetThemeColor(
  795. HTHEME hTheme,
  796. int iPartId,
  797. int iStateId,
  798. int iPropId,
  799. OUT COLORREF *pColor
  800. )
  801. {
  802. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  803. }
  804. static
  805. HRESULT
  806. WINAPI
  807. DrawThemeText(
  808. HTHEME hTheme,
  809. HDC hdc,
  810. int iPartId,
  811. int iStateId,
  812. LPCWSTR pszText,
  813. int iCharCount,
  814. DWORD dwTextFlags,
  815. DWORD dwTextFlags2,
  816. const RECT *pRect
  817. )
  818. {
  819. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  820. }
  821. static
  822. HRESULT
  823. WINAPI
  824. EnableThemeDialogTexture(
  825. HWND hwnd,
  826. DWORD dwFlags
  827. )
  828. {
  829. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  830. }
  831. static
  832. THEMEAPI_(BOOL)
  833. IsAppThemed()
  834. {
  835. return FALSE;
  836. }
  837. static THEMEAPI_(void) SetThemeAppProperties(DWORD dwFlags)
  838. {
  839. }
  840. static THEMEAPI_(HTHEME) GetWindowTheme(HWND hwnd)
  841. {
  842. return NULL;
  843. }
  844. static THEMEAPI_(BOOL) IsThemeDialogTextureEnabled(HWND hwnd)
  845. {
  846. return FALSE;
  847. }
  848. static THEMEAPI_(DWORD) GetThemeAppProperties()
  849. {
  850. return 0;
  851. }
  852. static THEMEAPI GetThemeFilename(HTHEME hTheme, int iPartId,
  853. int iStateId, int iPropId, OUT LPWSTR pszThemeFileName, int cchMaxBuffChars)
  854. {
  855. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  856. }
  857. static THEMEAPI GetThemeString(HTHEME hTheme, int iPartId,
  858. int iStateId, int iPropId, OUT LPWSTR pszBuff, int cchMaxBuffChars)
  859. {
  860. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  861. }
  862. static THEMEAPI GetThemeBool(HTHEME hTheme, int iPartId,
  863. int iStateId, int iPropId, OUT BOOL *pfVal)
  864. {
  865. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  866. }
  867. static THEMEAPI GetThemeIntList(HTHEME hTheme, int iPartId,
  868. int iStateId, int iPropId, OUT INTLIST *pIntList)
  869. {
  870. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  871. }
  872. static THEMEAPI GetThemeEnumValue(HTHEME hTheme, int iPartId,
  873. int iStateId, int iPropId, OUT int *piVal)
  874. {
  875. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  876. }
  877. static THEMEAPI GetThemePosition(HTHEME hTheme, int iPartId,
  878. int iStateId, int iPropId, OUT POINT *pPoint)
  879. {
  880. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  881. }
  882. static THEMEAPI GetThemeRect(HTHEME hTheme, int iPartId,
  883. int iStateId, int iPropId, OUT RECT *pRect)
  884. {
  885. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  886. }
  887. static THEMEAPI GetThemePropertyOrigin(HTHEME hTheme, int iPartId,
  888. int iStateId, int iPropId, OUT enum PROPERTYORIGIN *pOrigin)
  889. {
  890. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  891. }
  892. static THEMEAPI DrawThemeBackgroundEx(HTHEME hTheme, HDC hdc,
  893. int iPartId, int iStateId, const RECT *pRect, OPTIONAL const DTBGOPTS *pOptions)
  894. {
  895. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  896. }
  897. static THEMEAPI_(BOOL) ClassicAdjustWindowRectEx( LPRECT prcWnd, DWORD dwStyle,
  898. BOOL fMenu, DWORD dwExStyle )
  899. {
  900. return FALSE;
  901. }
  902. static THEMEAPI DumpLoadedThemeToTextFile(HTHEMEFILE hThemeFile,
  903. LPCWSTR pszTextFile, BOOL fPacked, BOOL fFullInfo)
  904. {
  905. return HRESULT_FROM_WIN32(ERROR_PROC_NOT_FOUND);
  906. }
  907. //---- fake some structs for these c++ classes ----
  908. typedef struct _CDrawBase {int dummy;} CDrawBase;
  909. typedef struct _CTextDraw {int dummy;} CTextDraw;
  910. static THEMEAPI_(HTHEME) CreateThemeDataFromObjects(OPTIONAL CDrawBase *pDrawObj,
  911. OPTIONAL CTextDraw *pTextObj, DWORD dwOtdFlags)
  912. {
  913. return NULL;
  914. }
  915. static THEMEAPI_(HTHEME) OpenThemeDataEx(HWND hwnd, LPCWSTR pszClassList, DWORD dwFlags)
  916. {
  917. return NULL;
  918. }
  919. //
  920. // !! WARNING !! The entries below must be in order by ORDINAL
  921. //
  922. DEFINE_ORDINAL_ENTRIES(uxtheme) // PRIVATE functions
  923. {
  924. DLOENTRY(1,QueryThemeServices)
  925. DLOENTRY(2,OpenThemeFile)
  926. DLOENTRY(3,CloseThemeFile)
  927. DLOENTRY(4,ApplyTheme)
  928. DLOENTRY(7,GetThemeDefaults)
  929. DLOENTRY(8,EnumThemes)
  930. DLOENTRY(9,EnumThemeColors)
  931. DLOENTRY(10,EnumThemeSizes)
  932. DLOENTRY(13,DrawNCPreview)
  933. DLOENTRY(14,RegisterDefaultTheme)
  934. DLOENTRY(15,DumpLoadedThemeToTextFile)
  935. DLOENTRY(16,OpenThemeDataFromFile)
  936. DLOENTRY(17,OpenThemeFileFromData)
  937. DLOENTRY(18,GetThemeSysSize96)
  938. DLOENTRY(19,GetThemeSysFont96)
  939. DLOENTRY(20,SessionAllocate)
  940. DLOENTRY(21,SessionFree)
  941. DLOENTRY(22,ThemeHooksOn)
  942. DLOENTRY(23,ThemeHooksOff)
  943. DLOENTRY(24,AreThemeHooksActive)
  944. DLOENTRY(25,GetCurrentChangeNumber)
  945. DLOENTRY(26,GetNewChangeNumber)
  946. DLOENTRY(27,SetGlobalTheme)
  947. DLOENTRY(28,GetGlobalTheme)
  948. DLOENTRY(29,CheckThemeSignature)
  949. DLOENTRY(30,LoadTheme)
  950. DLOENTRY(31,InitUserTheme)
  951. DLOENTRY(32,InitUserRegistry)
  952. DLOENTRY(33,ReestablishServerConnection)
  953. DLOENTRY(34,ThemeHooksInstall)
  954. DLOENTRY(35,ThemeHooksRemove)
  955. DLOENTRY(36,RefreshThemeForTS)
  956. DLOENTRY(43,ClassicGetSystemMetrics)
  957. DLOENTRY(44,ClassicSystemParametersInfoA)
  958. DLOENTRY(45,ClassicSystemParametersInfoW)
  959. DLOENTRY(46,ClassicAdjustWindowRectEx)
  960. DLOENTRY(47,DrawThemeBackgroundEx)
  961. DLOENTRY(48,GetThemeParseErrorInfo)
  962. DLOENTRY(60,CreateThemeDataFromObjects)
  963. DLOENTRY(61,OpenThemeDataEx)
  964. DLOENTRY(62,ServerClearStockObjects)
  965. DLOENTRY(63,MarkSection)
  966. // note: 64,ProcessLoadTheme_RunDLLW, doesn't need a d-load entry; it's strictly a GetProcAddress entrypoint.
  967. DLOENTRY(65,SetSystemVisualStyle)
  968. DLOENTRY(66,ServiceClearStockObjects)
  969. };
  970. DEFINE_ORDINAL_MAP(uxtheme)
  971. //
  972. // !! WARNING !! The entries below must be in alphabetical order, and are CASE SENSITIVE (eg lower case comes last!)
  973. //
  974. DEFINE_PROCNAME_ENTRIES(uxtheme) // PUBLIC functions
  975. {
  976. DLPENTRY(CloseThemeData)
  977. DLPENTRY(DrawThemeBackground)
  978. DLPENTRY(DrawThemeEdge)
  979. DLPENTRY(DrawThemeIcon)
  980. DLPENTRY(DrawThemeParentBackground)
  981. DLPENTRY(DrawThemeText)
  982. DLPENTRY(EnableThemeDialogTexture)
  983. DLPENTRY(EnableTheming)
  984. DLPENTRY(GetCurrentThemeName)
  985. DLPENTRY(GetThemeAppProperties)
  986. DLPENTRY(GetThemeBackgroundContentRect)
  987. DLPENTRY(GetThemeBackgroundExtent)
  988. DLPENTRY(GetThemeBackgroundRegion)
  989. DLPENTRY(GetThemeBool)
  990. DLPENTRY(GetThemeColor)
  991. DLPENTRY(GetThemeDocumentationProperty)
  992. DLPENTRY(GetThemeEnumValue)
  993. DLPENTRY(GetThemeFilename)
  994. DLPENTRY(GetThemeFont)
  995. DLPENTRY(GetThemeInt)
  996. DLPENTRY(GetThemeIntList)
  997. DLPENTRY(GetThemeMargins)
  998. DLPENTRY(GetThemeMetric)
  999. DLPENTRY(GetThemePartSize)
  1000. DLPENTRY(GetThemePosition)
  1001. DLPENTRY(GetThemePropertyOrigin)
  1002. DLPENTRY(GetThemeRect)
  1003. DLPENTRY(GetThemeString)
  1004. DLPENTRY(GetThemeSysBool)
  1005. DLPENTRY(GetThemeSysColor)
  1006. DLPENTRY(GetThemeSysColorBrush)
  1007. DLPENTRY(GetThemeSysFont)
  1008. DLPENTRY(GetThemeSysInt)
  1009. DLPENTRY(GetThemeSysSize)
  1010. DLPENTRY(GetThemeSysString)
  1011. DLPENTRY(GetThemeTextExtent)
  1012. DLPENTRY(GetThemeTextMetrics)
  1013. DLPENTRY(GetWindowTheme)
  1014. DLPENTRY(HitTestThemeBackground)
  1015. DLPENTRY(IsAppThemed)
  1016. DLPENTRY(IsThemeActive)
  1017. DLPENTRY(IsThemeBackgroundPartiallyTransparent)
  1018. DLPENTRY(IsThemeDialogTextureEnabled)
  1019. DLPENTRY(IsThemePartDefined)
  1020. DLPENTRY(OpenThemeData)
  1021. DLPENTRY(ServiceClearStockObjects)
  1022. DLPENTRY(SetSystemVisualStyle)
  1023. DLPENTRY(SetThemeAppProperties)
  1024. DLPENTRY(SetWindowTheme)
  1025. };
  1026. DEFINE_PROCNAME_MAP(uxtheme)