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.

1869 lines
35 KiB

  1. //
  2. // uwrap.h
  3. //
  4. // Unicode wrappers for Win32 API
  5. //
  6. // Inlucde this header to redirect any W calls
  7. // to wrappers that dynamically convert to ANSI
  8. // and call the A versions on non-unicode platforms
  9. //
  10. // Unlike the shlwapi wrappers which create a DLL
  11. // of wrapper functions, the ts uniwrappers work
  12. // by redefining functions to call into our wrapped
  13. // versions.
  14. //
  15. // Copyright(C) Microsoft Corporation 2000
  16. // Author: Nadim Abdo (nadima)
  17. //
  18. //
  19. #ifndef _uwrap_h_
  20. #define _uwrap_h_
  21. //Do not wrap on WIN64
  22. #if defined(UNICODE) && !defined(_WIN64)
  23. #include "shlobj.h"
  24. #include "winspool.h"
  25. #include "commdlg.h"
  26. #include "shellapi.h"
  27. #include "winnls32.h"
  28. //Group replacement wraps by module
  29. //these were autogenerated by genwrap.pl
  30. //Define this to avoid replacing, i.e just
  31. //include the wrap function definitions.
  32. //Need to do this in the implementation class.
  33. #ifndef DONOT_REPLACE_WITH_WRAPPERS
  34. //
  35. // ADVAPI32.dll
  36. #ifdef RegEnumKey
  37. #undef RegEnumKey
  38. #endif
  39. #define RegEnumKey RegEnumKeyWrapW
  40. #ifdef RegOpenKeyEx
  41. #undef RegOpenKeyEx
  42. #endif
  43. #define RegOpenKeyEx RegOpenKeyExWrapW
  44. #ifdef RegEnumValue
  45. #undef RegEnumValue
  46. #endif
  47. #define RegEnumValue RegEnumValueWrapW
  48. #ifdef RegEnumKeyEx
  49. #undef RegEnumKeyEx
  50. #endif
  51. #define RegEnumKeyEx RegEnumKeyExWrapW
  52. #ifdef RegDeleteValue
  53. #undef RegDeleteValue
  54. #endif
  55. #define RegDeleteValue RegDeleteValueWrapW
  56. #ifdef RegCreateKeyEx
  57. #undef RegCreateKeyEx
  58. #endif
  59. #define RegCreateKeyEx RegCreateKeyExWrapW
  60. #ifdef RegSetValueEx
  61. #undef RegSetValueEx
  62. #endif
  63. #define RegSetValueEx RegSetValueExWrapW
  64. #ifdef GetUserName
  65. #undef GetUserName
  66. #endif
  67. #define GetUserName GetUserNameWrapW
  68. #ifdef RegQueryValueEx
  69. #undef RegQueryValueEx
  70. #endif
  71. #define RegQueryValueEx RegQueryValueExWrapW
  72. #ifdef GetClassInfoEx
  73. #undef GetClassInfoEx
  74. #endif
  75. #define GetClassInfoEx GetClassInfoExWrapW
  76. //atlwin.h makes a direct call to the W version
  77. //of this API so wrap that
  78. #ifdef GetClassInfoExW
  79. #undef GetClassInfoExW
  80. #endif
  81. #define GetClassInfoExW GetClassInfoExWrapW
  82. #ifdef UnregisterClass
  83. #undef UnregisterClass
  84. #endif
  85. #define UnregisterClass UnregisterClassWrapW
  86. #ifdef RegOpenKey
  87. #undef RegOpenKey
  88. #endif
  89. #define RegOpenKey RegOpenKeyWrapW
  90. #ifdef RegDeleteKey
  91. #undef RegDeleteKey
  92. #endif
  93. #define RegDeleteKey RegDeleteKeyWrapW
  94. #ifdef RegQueryInfoKey
  95. #undef RegQueryInfoKey
  96. #endif
  97. #define RegQueryInfoKey RegQueryInfoKeyWrapW
  98. #ifdef GetFileSecurity
  99. #undef GetFileSecurity
  100. #endif
  101. #define GetFileSecurity GetFileSecurityWrapW
  102. #ifdef SetFileSecurity
  103. #undef SetFileSecurity
  104. #endif
  105. #define SetFileSecurity SetFileSecurityWrapW
  106. // KERNEL32.dll
  107. #ifdef CreateProcess
  108. #undef CreateProcess
  109. #endif
  110. #define CreateProcess CreateProcessWrapW
  111. #ifdef DeleteFile
  112. #undef DeleteFile
  113. #endif
  114. #define DeleteFile DeleteFileWrapW
  115. #ifdef CreateDirectory
  116. #undef CreateDirectory
  117. #endif
  118. #define CreateDirectory CreateDirectoryWrapW
  119. #ifdef GetCommandLine
  120. #undef GetCommandLine
  121. #endif
  122. #define GetCommandLine GetCommandLineWrapW
  123. #ifdef GetEnvironmentStrings
  124. #undef GetEnvironmentStrings
  125. #endif
  126. #define GetEnvironmentStrings GetEnvironmentStringsWrapW
  127. #ifdef FreeEnvironmentStrings
  128. #undef FreeEnvironmentStrings
  129. #endif
  130. #define FreeEnvironmentStrings FreeEnvironmentStringsWrapW
  131. #ifdef LCMapString
  132. #undef LCMapString
  133. #endif
  134. #define LCMapString LCMapStringWrapW
  135. #ifdef GetStringType
  136. #undef GetStringType
  137. #endif
  138. #define GetStringType GetStringTypeWrapW
  139. #ifdef CreateEvent
  140. #undef CreateEvent
  141. #endif
  142. #define CreateEvent CreateEventWrapW
  143. #ifdef FormatMessage
  144. #undef FormatMessage
  145. #endif
  146. #define FormatMessage FormatMessageWrapW
  147. #ifdef lstrcpy
  148. #undef lstrcpy
  149. #endif
  150. #define lstrcpy lstrcpyWrapW
  151. #define lstrcpyW lstrcpyWrapW
  152. #ifdef lstrcpyn
  153. #undef lstrcpyn
  154. #endif
  155. #define lstrcpyn lstrcpynWrapW
  156. #ifdef lstrcat
  157. #undef lstrcat
  158. #endif
  159. #define lstrcat lstrcatWrapW
  160. #ifdef lstrcmpi
  161. #undef lstrcmpi
  162. #endif
  163. #define lstrcmpi lstrcmpiWrapW
  164. #ifdef FindResource
  165. #undef FindResource
  166. #endif
  167. #define FindResource FindResourceWrapW
  168. #ifdef GetVersionEx
  169. #undef GetVersionEx
  170. #endif
  171. #define GetVersionEx GetVersionExWrapW
  172. #ifdef GetTempPath
  173. #undef GetTempPath
  174. #endif
  175. #define GetTempPath GetTempPathWrapW
  176. #ifdef GetTempFileName
  177. #undef GetTempFileName
  178. #endif
  179. #define GetTempFileName GetTempFileNameWrapW
  180. #ifdef CreateFileMapping
  181. #undef CreateFileMapping
  182. #endif
  183. #define CreateFileMapping CreateFileMappingWrapW
  184. #ifdef CreateMutex
  185. #undef CreateMutex
  186. #endif
  187. #define CreateMutex CreateMutexWrapW
  188. #ifdef OutputDebugString
  189. #undef OutputDebugString
  190. #endif
  191. #define OutputDebugString OutputDebugStringWrapW
  192. #ifdef OutputDebugStringW
  193. #undef OutputDebugStringW
  194. #endif
  195. #define OutputDebugStringW OutputDebugStringWrapW
  196. #ifdef CreateFile
  197. #undef CreateFile
  198. #endif
  199. #define CreateFile CreateFileWrapW
  200. #ifdef ExpandEnvironmentStrings
  201. #undef ExpandEnvironmentStrings
  202. #endif
  203. #define ExpandEnvironmentStrings ExpandEnvironmentStringsWrapW
  204. #ifdef GetStartupInfo
  205. #undef GetStartupInfo
  206. #endif
  207. #define GetStartupInfo GetStartupInfoWrapW
  208. #ifdef GetModuleHandle
  209. #undef GetModuleHandle
  210. #endif
  211. #define GetModuleHandle GetModuleHandleWrapW
  212. #ifdef GetModuleFileName
  213. #undef GetModuleFileName
  214. #endif
  215. #define GetModuleFileName GetModuleFileNameWrapW
  216. #ifdef SetFileAttributes
  217. #undef SetFileAttributes
  218. #endif
  219. #define SetFileAttributes SetFileAttributesWrapW
  220. #ifdef GetFileAttributes
  221. #undef GetFileAttributes
  222. #endif
  223. #define GetFileAttributes GetFileAttributesWrapW
  224. #ifdef RemoveDirectory
  225. #undef RemoveDirectory
  226. #endif
  227. #define RemoveDirectory RemoveDirectoryWrapW
  228. #ifdef FindFirstFile
  229. #undef FindFirstFile
  230. #endif
  231. #define FindFirstFile FindFirstFileWrapW
  232. #ifdef FindNextFile
  233. #undef FindNextFile
  234. #endif
  235. #define FindNextFile FindNextFileWrapW
  236. #ifdef GetDiskFreeSpace
  237. #undef GetDiskFreeSpace
  238. #endif
  239. #define GetDiskFreeSpace GetDiskFreeSpaceWrapW
  240. #ifdef GetFullPathName
  241. #undef GetFullPathName
  242. #endif
  243. #define GetFullPathName GetFullPathNameWrapW
  244. #ifdef GetComputerName
  245. #undef GetComputerName
  246. #endif
  247. #define GetComputerName GetComputerNameWrapW
  248. //RDPDR makes a direct call to the W api
  249. #ifdef GetComputerNameW
  250. #undef GetComputerNameW
  251. #endif
  252. #define GetComputerNameW GetComputerNameWrapW
  253. #ifdef CreateSemaphore
  254. #undef CreateSemaphore
  255. #endif
  256. #define CreateSemaphore CreateSemaphoreWrapW
  257. #ifdef GetDriveType
  258. #undef GetDriveType
  259. #endif
  260. #define GetDriveType GetDriveTypeWrapW
  261. #ifdef FindFirstChangeNotification
  262. #undef FindFirstChangeNotification
  263. #endif
  264. #define FindFirstChangeNotification FindFirstChangeNotificationWrapW
  265. #ifdef GetVolumeInformation
  266. #undef GetVolumeInformation
  267. #endif
  268. #define GetVolumeInformation GetVolumeInformationWrapW
  269. #ifdef MoveFile
  270. #undef MoveFile
  271. #endif
  272. #define MoveFile MoveFileWrapW
  273. #ifdef GetProfileString
  274. #undef GetProfileString
  275. #endif
  276. #define GetProfileString GetProfileStringWrapW
  277. #ifdef CreateDirectory
  278. #undef CreateDirectory
  279. #endif
  280. #define CreateDirectory CreateDirectoryWrapW
  281. #ifdef LoadLibrary
  282. #undef LoadLibrary
  283. #endif
  284. #define LoadLibrary LoadLibraryWrapW
  285. #ifdef LoadLibraryEx
  286. #undef LoadLibraryEx
  287. #endif
  288. #define LoadLibraryEx LoadLibraryExWrapW
  289. #ifdef GetShortPathName
  290. #undef GetShortPathName
  291. #endif
  292. #define GetShortPathName GetShortPathNameWrapW
  293. #ifdef GetSystemDirectory
  294. #undef GetSystemDirectory
  295. #endif
  296. #define GetSystemDirectory GetSystemDirectoryWrapW
  297. #ifdef DrawText
  298. #undef DrawText
  299. #endif
  300. #define DrawText DrawTextWrapW
  301. #ifdef GetDefaultCommConfig
  302. #undef GetDefaultCommConfig
  303. #endif
  304. #define GetDefaultCommConfig GetDefaultCommConfigWrapW
  305. #ifdef GetCurrentDirectory
  306. #undef GetCurrentDirectory
  307. #endif
  308. #define GetCurrentDirectory GetCurrentDirectoryWrapW
  309. // GDI32.dll
  310. #ifdef CreateDC
  311. #undef CreateDC
  312. #endif
  313. #define CreateDC CreateDCWrapW
  314. #ifdef CreateMetaFile
  315. #undef CreateMetaFile
  316. #endif
  317. #define CreateMetaFile CreateMetaFileWrapW
  318. #ifdef GetObject
  319. #undef GetObject
  320. #endif
  321. #define GetObject GetObjectWrapW
  322. #ifdef CreateFontIndirect
  323. #undef CreateFontIndirect
  324. #endif
  325. #define CreateFontIndirect CreateFontIndirectWrapW
  326. #ifdef GetTextExtentPoint
  327. #undef GetTextExtentPoint
  328. #endif
  329. #define GetTextExtentPoint GetTextExtentPointWrapW
  330. #ifdef ExtTextOut
  331. #undef ExtTextOut
  332. #endif
  333. #define ExtTextOut ExtTextOutWrapW
  334. #ifdef GetTextMetrics
  335. #undef GetTextMetrics
  336. #endif
  337. #define GetTextMetrics GetTextMetricsWrapW
  338. // USER32.dll
  339. #ifdef SetClassLong
  340. #undef SetClassLong
  341. #endif
  342. #define SetClassLong SetClassLongWrapW
  343. #ifdef SetClassLongPtr
  344. #undef SetClassLongPtr
  345. #endif
  346. #define SetClassLongPtr SetClassLongPtrWrapW
  347. #ifdef PeekMessage
  348. #undef PeekMessage
  349. #endif
  350. #define PeekMessage PeekMessageWrapW
  351. #ifdef MapVirtualKey
  352. #undef MapVirtualKey
  353. #endif
  354. #define MapVirtualKey MapVirtualKeyWrapW
  355. #ifdef SetWindowsHookEx
  356. #undef SetWindowsHookEx
  357. #endif
  358. #define SetWindowsHookEx SetWindowsHookExWrapW
  359. #ifdef PostThreadMessage
  360. #undef PostThreadMessage
  361. #endif
  362. #define PostThreadMessage PostThreadMessageWrapW
  363. #ifdef GetClipboardFormatName
  364. #undef GetClipboardFormatName
  365. #endif
  366. #define GetClipboardFormatName GetClipboardFormatNameWrapW
  367. #ifdef RegisterClipboardFormat
  368. #undef RegisterClipboardFormat
  369. #endif
  370. #define RegisterClipboardFormat RegisterClipboardFormatWrapW
  371. #ifdef CreateDialog
  372. #undef CreateDialog
  373. #endif
  374. #define CreateDialog(hInstance, lpName, hWndParent, lpDialogFunc) \
  375. CreateDialogParamWrapW(hInstance, lpName, hWndParent, lpDialogFunc, 0L)
  376. #ifdef CreateDialogIndirect
  377. #undef CreateDialogIndirect
  378. #endif
  379. #define CreateDialogIndirect(hInstance, lpTemplate, hWndParent, lpDialogFunc) \
  380. CreateDialogIndirectParamWrapW(hInstance, lpTemplate, hWndParent, lpDialogFunc, 0L)
  381. #ifdef CreateDialogIndirectParam
  382. #undef CreateDialogIndirectParam
  383. #endif
  384. #define CreateDialogIndirectParam CreateDialogIndirectParamWrapW
  385. #ifdef DispatchMessage
  386. #undef DispatchMessage
  387. #endif
  388. #define DispatchMessage DispatchMessageWrapW
  389. #ifdef CreateDialogParam
  390. #undef CreateDialogParam
  391. #endif
  392. #define CreateDialogParam CreateDialogParamWrapW
  393. #ifdef IsDialogMessage
  394. #undef IsDialogMessage
  395. #endif
  396. #define IsDialogMessage IsDialogMessageWrapW
  397. #ifdef SetDlgItemText
  398. #undef SetDlgItemText
  399. #endif
  400. #define SetDlgItemText SetDlgItemTextWrapW
  401. #ifdef LoadImage
  402. #undef LoadImage
  403. #endif
  404. #define LoadImage LoadImageWrapW
  405. #ifdef GetDlgItemText
  406. #undef GetDlgItemText
  407. #endif
  408. #define GetDlgItemText GetDlgItemTextWrapW
  409. #ifdef SendDlgItemMessage
  410. #undef SendDlgItemMessage
  411. #endif
  412. #define SendDlgItemMessage SendDlgItemMessageWrapW
  413. #ifdef GetWindowText
  414. #undef GetWindowText
  415. #endif
  416. #define GetWindowText GetWindowTextWrapW
  417. #ifdef DialogBoxParam
  418. #undef DialogBoxParam
  419. #endif
  420. #define DialogBoxParam DialogBoxParamWrapW
  421. #ifdef DialogBox
  422. #undef DialogBox
  423. #endif
  424. #define DialogBox(hInstance, lpTemplate, hWndParent, lpDialogFunc) \
  425. DialogBoxParamWrapW(hInstance, lpTemplate, hWndParent, lpDialogFunc, 0L)
  426. #ifdef RegisterClassEx
  427. #undef RegisterClassEx
  428. #endif
  429. #define RegisterClassEx RegisterClassExWrapW
  430. //ATL makes a direct call to the W version of this
  431. //API so wrap it directly
  432. #ifdef RegisterClassExW
  433. #undef RegisterClassExW
  434. #endif
  435. #define RegisterClassExW RegisterClassExWrapW
  436. #ifdef LoadIcon
  437. #undef LoadIcon
  438. #endif
  439. #define LoadIcon LoadIconWrapW
  440. #ifdef GetWindowLong
  441. #undef GetWindowLong
  442. #endif
  443. #define GetWindowLong GetWindowLongWrapW
  444. #ifdef GetKeyboardLayoutName
  445. #undef GetKeyboardLayoutName
  446. #endif
  447. #define GetKeyboardLayoutName GetKeyboardLayoutNameWrapW
  448. #ifdef GetWindowLongPtr
  449. #undef GetWindowLongPtr
  450. #endif
  451. #define GetWindowLongPtr GetWindowLongPtrWrapW
  452. #ifdef CreateWindowEx
  453. #undef CreateWindowEx
  454. #endif
  455. #define CreateWindowEx CreateWindowExWrapW
  456. //Special case CreateWindow because it's
  457. //a macro to CreateWindowEx
  458. #ifdef CreateWindow
  459. #undef CreateWindow
  460. #endif
  461. #define CreateWindow(lpClassName, lpWindowName, dwStyle, x, y,\
  462. nWidth, nHeight, hWndParent, hMenu, hInstance, lpParam)\
  463. CreateWindowExWrapW(0L, lpClassName, lpWindowName, dwStyle, x, y,\
  464. nWidth, nHeight, hWndParent, hMenu, hInstance, lpParam)
  465. #ifdef PostMessage
  466. #undef PostMessage
  467. #endif
  468. #define PostMessage PostMessageWrapW
  469. #ifdef SetWindowLong
  470. #undef SetWindowLong
  471. #endif
  472. #define SetWindowLong SetWindowLongWrapW
  473. #ifdef SetWindowLongPtr
  474. #undef SetWindowLongPtr
  475. #endif
  476. #define SetWindowLongPtr SetWindowLongPtrWrapW
  477. #ifdef SendMessage
  478. #undef SendMessage
  479. #endif
  480. #define SendMessage SendMessageWrapW
  481. #ifdef SetWindowText
  482. #undef SetWindowText
  483. #endif
  484. #define SetWindowText SetWindowTextWrapW
  485. #ifdef WinHelp
  486. #undef WinHelp
  487. #endif
  488. #define WinHelp WinHelpWrapW
  489. #ifdef DefWindowProc
  490. #undef DefWindowProc
  491. #endif
  492. #define DefWindowProc DefWindowProcWrapW
  493. #ifdef CallWindowProc
  494. #undef CallWindowProc
  495. #endif
  496. #define CallWindowProc CallWindowProcWrapW
  497. #ifdef MessageBox
  498. #undef MessageBox
  499. #endif
  500. #define MessageBox MessageBoxWrapW
  501. #ifdef LoadCursor
  502. #undef LoadCursor
  503. #endif
  504. #define LoadCursor LoadCursorWrapW
  505. //ATL makes a direct call to LoadCursorW
  506. #ifdef LoadCursorW
  507. #undef LoadCursorW
  508. #endif
  509. #define LoadCursorW LoadCursorWrapW
  510. #ifdef ModifyMenu
  511. #undef ModifyMenu
  512. #endif
  513. #define ModifyMenu ModifyMenuWrapW
  514. #ifdef AppendMenu
  515. #undef AppendMenu
  516. #endif
  517. #define AppendMenu AppendMenuWrapW
  518. #ifdef LoadString
  519. #undef LoadString
  520. #endif
  521. #define LoadString LoadStringWrapW
  522. #ifdef RegisterClass
  523. #undef RegisterClass
  524. #endif
  525. #define RegisterClass RegisterClassWrapW
  526. #ifdef GetMessage
  527. #undef GetMessage
  528. #endif
  529. #define GetMessage GetMessageWrapW
  530. #ifdef LoadAccelerators
  531. #undef LoadAccelerators
  532. #endif
  533. #define LoadAccelerators LoadAcceleratorsWrapW
  534. #ifdef CharNext
  535. #undef CharNext
  536. #endif
  537. #define CharNext CharNextWrapW
  538. //Some ATL code explicitly calls CharNextW
  539. #ifdef CharNextW
  540. #undef CharNextW
  541. #endif
  542. #define CharNextW CharNextWrapW
  543. // SHELL32.dll
  544. #ifdef SHGetPathFromIDList
  545. #undef SHGetPathFromIDList
  546. #endif
  547. #define SHGetPathFromIDList SHGetPathFromIDListWrapW
  548. #ifdef ExtractIcon
  549. #undef ExtractIcon
  550. #endif
  551. #define ExtractIcon ExtractIconWrapW
  552. //HACK! Remap wsprintf to the va_list version
  553. #ifdef wsprintfW
  554. #undef wsprintfW
  555. #endif
  556. #define wsprintfW wsprintfWrapW
  557. #ifdef wvsprintfW
  558. #undef wvsprintfW
  559. #endif
  560. #define wvsprintfW wvsprintfWrapW
  561. #ifdef SHFileOperation
  562. #undef SHFileOperation
  563. #endif
  564. #define SHFileOperation SHFileOperationWrapW
  565. // comdlg32.dll
  566. #ifdef GetSaveFileName
  567. #undef GetSaveFileName
  568. #endif
  569. #define GetSaveFileName GetSaveFileNameWrapW
  570. #ifdef GetFileTitle
  571. #undef GetFileTitle
  572. #endif
  573. #define GetFileTitle GetFileTitleWrapW
  574. #ifdef GetOpenFileName
  575. #undef GetOpenFileName
  576. #endif
  577. #define GetOpenFileName GetOpenFileNameWrapW
  578. // shell32.dll
  579. #ifdef SHGetFolderPath
  580. #undef SHGetFolderPath
  581. #endif
  582. #define SHGetFolderPath SHGetFolderPathWrapW
  583. // winspool.lib
  584. #ifdef EnumPrinters
  585. #undef EnumPrinters
  586. #endif
  587. #define EnumPrinters EnumPrintersWrapW
  588. #ifdef OpenPrinter
  589. #undef OpenPrinter
  590. #endif
  591. #define OpenPrinter OpenPrinterWrapW
  592. #ifdef StartDocPrinter
  593. #undef StartDocPrinter
  594. #endif
  595. #define StartDocPrinter StartDocPrinterWrapW
  596. #ifdef GetPrinterData
  597. #undef GetPrinterData
  598. #endif
  599. #define GetPrinterData GetPrinterDataWrapW
  600. #ifdef GetPrinterDriver
  601. #undef GetPrinterDriver
  602. #endif
  603. #define GetPrinterDriver GetPrinterDriverWrapW
  604. // this is a hack around ATL problems:
  605. // Wrap in two phases, second phase
  606. // wrap is after including ATL headers
  607. // that have member function names that conflict
  608. // with win32 APIs.
  609. //
  610. #ifndef DONOT_INCLUDE_SECONDPHASE_WRAPS
  611. #include "uwrap2.h"
  612. #endif
  613. #endif // DONOT_REPLACE_WITH_WRAPPERS
  614. //
  615. // Wrapper function definitions these are identitcal to the definitions
  616. // for the 'W' functions
  617. //
  618. #define DEFINE_WRAPPER_FNS
  619. #ifdef DEFINE_WRAPPER_FNS
  620. //
  621. //To create these, simply copy the 'W' version
  622. //declaration from the windows headers and append WrapW.
  623. //There is no automated way.
  624. //
  625. #ifdef __cplusplus
  626. extern "C" {
  627. #endif
  628. //Advapi32.dll
  629. LONG
  630. APIENTRY
  631. RegEnumKeyWrapW (
  632. IN HKEY hKey,
  633. IN DWORD dwIndex,
  634. OUT LPWSTR lpName,
  635. IN DWORD cbName
  636. );
  637. LONG
  638. APIENTRY
  639. RegOpenKeyExWrapW (
  640. IN HKEY hKey,
  641. IN LPCWSTR lpSubKey,
  642. IN DWORD ulOptions,
  643. IN REGSAM samDesired,
  644. OUT PHKEY phkResult
  645. );
  646. LONG
  647. APIENTRY
  648. RegEnumKeyExWrapW (
  649. IN HKEY hKey,
  650. IN DWORD dwIndex,
  651. OUT LPWSTR lpName,
  652. IN OUT LPDWORD lpcbName,
  653. IN LPDWORD lpReserved,
  654. IN OUT LPWSTR lpClass,
  655. IN OUT LPDWORD lpcbClass,
  656. OUT PFILETIME lpftLastWriteTime
  657. );
  658. LONG
  659. APIENTRY
  660. RegEnumValueWrapW (
  661. IN HKEY hKey,
  662. IN DWORD dwIndex,
  663. OUT LPWSTR lpValueName,
  664. IN OUT LPDWORD lpcbValueName,
  665. IN LPDWORD lpReserved,
  666. OUT LPDWORD lpType,
  667. OUT LPBYTE lpData,
  668. IN OUT LPDWORD lpcbData
  669. );
  670. LONG
  671. APIENTRY
  672. RegDeleteValueWrapW (
  673. IN HKEY hKey,
  674. IN LPCWSTR lpValueName
  675. );
  676. LONG
  677. APIENTRY
  678. RegCreateKeyExWrapW (
  679. IN HKEY hKey,
  680. IN LPCWSTR lpSubKey,
  681. IN DWORD Reserved,
  682. IN LPWSTR lpClass,
  683. IN DWORD dwOptions,
  684. IN REGSAM samDesired,
  685. IN LPSECURITY_ATTRIBUTES lpSecurityAttributes,
  686. OUT PHKEY phkResult,
  687. OUT LPDWORD lpdwDisposition
  688. );
  689. LONG
  690. APIENTRY
  691. RegSetValueExWrapW (
  692. IN HKEY hKey,
  693. IN LPCWSTR lpValueName,
  694. IN DWORD Reserved,
  695. IN DWORD dwType,
  696. IN CONST BYTE* lpData,
  697. IN DWORD cbData
  698. );
  699. LONG
  700. APIENTRY
  701. RegSetValueWrapW (
  702. IN HKEY hKey,
  703. IN LPCWSTR lpSubKey,
  704. IN DWORD dwType,
  705. IN LPCWSTR lpData,
  706. IN DWORD cbData
  707. );
  708. BOOL
  709. WINAPI
  710. GetUserNameWrapW (
  711. OUT LPWSTR lpBuffer,
  712. IN OUT LPDWORD nSize
  713. );
  714. LONG
  715. APIENTRY
  716. RegQueryValueExWrapW (
  717. IN HKEY hKey,
  718. IN LPCWSTR lpValueName,
  719. IN LPDWORD lpReserved,
  720. OUT LPDWORD lpType,
  721. IN OUT LPBYTE lpData,
  722. IN OUT LPDWORD lpcbData
  723. );
  724. LONG
  725. APIENTRY
  726. RegDeleteKeyWrapW (
  727. IN HKEY hKey,
  728. IN LPCWSTR lpSubKey
  729. );
  730. LONG
  731. APIENTRY
  732. RegQueryInfoKeyWrapW (
  733. IN HKEY hKey,
  734. OUT LPWSTR lpClass,
  735. IN OUT LPDWORD lpcbClass,
  736. IN LPDWORD lpReserved,
  737. OUT LPDWORD lpcSubKeys,
  738. OUT LPDWORD lpcbMaxSubKeyLen,
  739. OUT LPDWORD lpcbMaxClassLen,
  740. OUT LPDWORD lpcValues,
  741. OUT LPDWORD lpcbMaxValueNameLen,
  742. OUT LPDWORD lpcbMaxValueLen,
  743. OUT LPDWORD lpcbSecurityDescriptor,
  744. OUT PFILETIME lpftLastWriteTime
  745. );
  746. LONG
  747. APIENTRY
  748. RegOpenKeyWrapW (
  749. IN HKEY hKey,
  750. IN LPCWSTR lpSubKey,
  751. OUT PHKEY phkResult
  752. );
  753. BOOL
  754. WINAPI
  755. GetFileSecurityWrapW (
  756. IN LPCWSTR lpFileName,
  757. IN SECURITY_INFORMATION RequestedInformation,
  758. OUT PSECURITY_DESCRIPTOR pSecurityDescriptor,
  759. IN DWORD nLength,
  760. OUT LPDWORD lpnLengthNeeded
  761. );
  762. BOOL
  763. WINAPI
  764. SetFileSecurityWrapW (
  765. IN LPCWSTR lpFileName,
  766. IN SECURITY_INFORMATION SecurityInformation,
  767. IN PSECURITY_DESCRIPTOR pSecurityDescriptor
  768. );
  769. //Kernel32.dll
  770. BOOL
  771. WINAPI
  772. DeleteFileWrapW(
  773. IN LPCWSTR lpFileName
  774. );
  775. BOOL
  776. WINAPI
  777. CreateProcessWrapW(
  778. IN LPCWSTR lpApplicationName,
  779. IN OUT LPWSTR lpCommandLine,
  780. IN LPSECURITY_ATTRIBUTES lpProcessAttributes,
  781. IN LPSECURITY_ATTRIBUTES lpThreadAttributes,
  782. IN BOOL bInheritHandles,
  783. IN DWORD dwCreationFlags,
  784. IN LPVOID lpEnvironment,
  785. IN LPCWSTR lpCurrentDirectory,
  786. IN LPSTARTUPINFOW lpStartupInfo,
  787. OUT LPPROCESS_INFORMATION lpProcessInformation
  788. );
  789. BOOL
  790. WINAPI
  791. CreateDirectoryWrapW(
  792. IN LPCWSTR lpPathName,
  793. IN LPSECURITY_ATTRIBUTES lpSecurityAttributes
  794. );
  795. LPWSTR
  796. WINAPI
  797. GetCommandLineWrapW(
  798. VOID
  799. );
  800. LPWSTR
  801. WINAPI
  802. GetEnvironmentStringsWrapW(
  803. VOID
  804. );
  805. BOOL
  806. WINAPI
  807. FreeEnvironmentStringsWrapW(
  808. IN LPWSTR
  809. );
  810. int
  811. WINAPI
  812. LCMapStringWrapW(
  813. IN LCID Locale,
  814. IN DWORD dwMapFlags,
  815. IN LPCWSTR lpSrcStr,
  816. IN int cchSrc,
  817. OUT LPWSTR lpDestStr,
  818. IN int cchDest);
  819. BOOL
  820. WINAPI
  821. GetStringTypeWrapW(
  822. IN DWORD dwInfoType,
  823. IN LPCWSTR lpSrcStr,
  824. IN int cchSrc,
  825. OUT LPWORD lpCharType);
  826. HANDLE
  827. WINAPI
  828. CreateEventWrapW(
  829. IN LPSECURITY_ATTRIBUTES lpEventAttributes,
  830. IN BOOL bManualReset,
  831. IN BOOL bInitialState,
  832. IN LPCWSTR lpName
  833. );
  834. DWORD
  835. WINAPI
  836. FormatMessageWrapW(
  837. IN DWORD dwFlags,
  838. IN LPCVOID lpSource,
  839. IN DWORD dwMessageId,
  840. IN DWORD dwLanguageId,
  841. OUT LPWSTR lpBuffer,
  842. IN DWORD nSize,
  843. IN va_list *Arguments
  844. );
  845. LPWSTR
  846. WINAPI
  847. lstrcpyWrapW(
  848. OUT LPWSTR lpString1,
  849. IN LPCWSTR lpString2
  850. );
  851. LPWSTR
  852. lstrcatWrapW(
  853. OUT LPWSTR pszDst,
  854. IN LPCWSTR pszSrc
  855. );
  856. LPWSTR
  857. lstrcpynWrapW(
  858. LPWSTR lpString1,
  859. LPCWSTR lpString2,
  860. int iMaxLength
  861. );
  862. INT
  863. APIENTRY
  864. lstrcmpiWrapW(
  865. LPCWSTR lpString1,
  866. LPCWSTR lpString2
  867. );
  868. HRSRC
  869. WINAPI
  870. FindResourceWrapW(
  871. IN HMODULE hModule,
  872. IN LPCWSTR lpName,
  873. IN LPCWSTR lpType
  874. );
  875. BOOL
  876. WINAPI
  877. GetVersionExWrapW(
  878. IN OUT LPOSVERSIONINFOW lpVersionInformation
  879. );
  880. DWORD
  881. WINAPI
  882. GetTempPathWrapW(
  883. IN DWORD nBufferLength,
  884. OUT LPWSTR lpBuffer
  885. );
  886. UINT
  887. WINAPI
  888. GetTempFileNameWrapW(
  889. IN LPCWSTR lpPathName,
  890. IN LPCWSTR lpPrefixString,
  891. IN UINT uUnique,
  892. OUT LPWSTR lpTempFileName
  893. );
  894. HANDLE
  895. WINAPI
  896. CreateFileMappingWrapW(
  897. IN HANDLE hFile,
  898. IN LPSECURITY_ATTRIBUTES lpFileMappingAttributes,
  899. IN DWORD flProtect,
  900. IN DWORD dwMaximumSizeHigh,
  901. IN DWORD dwMaximumSizeLow,
  902. IN LPCWSTR lpName
  903. );
  904. HANDLE
  905. WINAPI
  906. CreateMutexWrapW(
  907. LPSECURITY_ATTRIBUTES lpMutexAttributes,
  908. BOOL bInitialOwner,
  909. LPCWSTR pwzName);
  910. UINT
  911. WINAPI
  912. GetSystemDirectoryWrapW(
  913. OUT LPWSTR lpBuffer,
  914. IN UINT uSize
  915. );
  916. VOID
  917. WINAPI
  918. OutputDebugStringWrapW(
  919. IN LPCWSTR lpOutputString
  920. );
  921. int
  922. WINAPI
  923. DrawTextWrapW(
  924. IN HDC hDC,
  925. IN LPCWSTR lpString,
  926. IN int nCount,
  927. IN OUT LPRECT lpRect,
  928. IN UINT uFormat);
  929. HANDLE
  930. WINAPI
  931. CreateFileWrapW(
  932. IN LPCWSTR lpFileName,
  933. IN DWORD dwDesiredAccess,
  934. IN DWORD dwShareMode,
  935. IN LPSECURITY_ATTRIBUTES lpSecurityAttributes,
  936. IN DWORD dwCreationDisposition,
  937. IN DWORD dwFlagsAndAttributes,
  938. IN HANDLE hTemplateFile
  939. );
  940. DWORD
  941. WINAPI
  942. ExpandEnvironmentStringsWrapW(
  943. IN LPCWSTR lpSrc,
  944. OUT LPWSTR lpDst,
  945. IN DWORD nSize
  946. );
  947. VOID
  948. WINAPI
  949. GetStartupInfoWrapW(
  950. OUT LPSTARTUPINFOW lpStartupInfo
  951. );
  952. HMODULE
  953. WINAPI
  954. GetModuleHandleWrapW(
  955. IN LPCWSTR lpModuleName
  956. );
  957. DWORD
  958. WINAPI
  959. GetModuleFileNameWrapW(
  960. IN HMODULE hModule,
  961. OUT LPWSTR lpFilename,
  962. IN DWORD nSize
  963. );
  964. HMODULE
  965. WINAPI
  966. LoadLibraryWrapW(
  967. IN LPCWSTR lpLibFileName
  968. );
  969. DWORD
  970. WINAPI
  971. GetShortPathNameWrapW(
  972. IN LPCWSTR lpszLongPath,
  973. OUT LPWSTR lpszShortPath,
  974. IN DWORD cchBuffer
  975. );
  976. HMODULE
  977. WINAPI
  978. LoadLibraryExWrapW(
  979. IN LPCWSTR lpLibFileName,
  980. IN HANDLE hFile,
  981. IN DWORD dwFlags
  982. );
  983. HANDLE
  984. WINAPI
  985. FindFirstFileWrapW(
  986. IN LPCWSTR lpFileName,
  987. OUT LPWIN32_FIND_DATAW lpFindFileData
  988. );
  989. BOOL
  990. WINAPI
  991. FindNextFileWrapW(
  992. IN HANDLE hFindFile,
  993. OUT LPWIN32_FIND_DATAW lpFindFileData
  994. );
  995. BOOL
  996. WINAPI
  997. GetDiskFreeSpaceWrapW(
  998. IN LPCWSTR lpRootPathName,
  999. OUT LPDWORD lpSectorsPerCluster,
  1000. OUT LPDWORD lpBytesPerSector,
  1001. OUT LPDWORD lpNumberOfFreeClusters,
  1002. OUT LPDWORD lpTotalNumberOfClusters
  1003. );
  1004. DWORD
  1005. WINAPI
  1006. GetFullPathNameWrapW(
  1007. IN LPCWSTR lpFileName,
  1008. IN DWORD nBufferLength,
  1009. OUT LPWSTR lpBuffer,
  1010. OUT LPWSTR *lpFilePart
  1011. );
  1012. BOOL
  1013. WINAPI
  1014. RemoveDirectoryWrapW(
  1015. IN LPCWSTR lpPathName
  1016. );
  1017. DWORD
  1018. WINAPI
  1019. GetFileAttributesWrapW(
  1020. IN LPCWSTR lpFileName
  1021. );
  1022. BOOL
  1023. WINAPI
  1024. SetFileAttributesWrapW(
  1025. IN LPCWSTR lpFileName,
  1026. IN DWORD dwFileAttributes
  1027. );
  1028. UINT
  1029. WINAPI
  1030. GetDriveTypeWrapW(
  1031. IN LPCWSTR lpRootPathName
  1032. );
  1033. HANDLE
  1034. WINAPI
  1035. FindFirstChangeNotificationWrapW(
  1036. IN LPCWSTR lpPathName,
  1037. IN BOOL bWatchSubtree,
  1038. IN DWORD dwNotifyFilter
  1039. );
  1040. BOOL
  1041. WINAPI
  1042. GetVolumeInformationWrapW(
  1043. IN LPCWSTR lpRootPathName,
  1044. OUT LPWSTR lpVolumeNameBuffer,
  1045. IN DWORD nVolumeNameSize,
  1046. OUT LPDWORD lpVolumeSerialNumber,
  1047. OUT LPDWORD lpMaximumComponentLength,
  1048. OUT LPDWORD lpFileSystemFlags,
  1049. OUT LPWSTR lpFileSystemNameBuffer,
  1050. IN DWORD nFileSystemNameSize
  1051. );
  1052. BOOL
  1053. WINAPI
  1054. MoveFileWrapW(
  1055. IN LPCWSTR lpExistingFileName,
  1056. IN LPCWSTR lpNewFileName
  1057. );
  1058. DWORD
  1059. WINAPI
  1060. GetProfileStringWrapW(
  1061. IN LPCWSTR lpAppName,
  1062. IN LPCWSTR lpKeyName,
  1063. IN LPCWSTR lpDefault,
  1064. OUT LPWSTR lpReturnedString,
  1065. IN DWORD nSize
  1066. );
  1067. BOOL
  1068. WINAPI
  1069. GetDefaultCommConfigWrapW(
  1070. IN LPCWSTR lpszName,
  1071. OUT LPCOMMCONFIG lpCC,
  1072. IN OUT LPDWORD lpdwSize
  1073. );
  1074. DWORD
  1075. WINAPI
  1076. GetCurrentDirectoryWrapW(
  1077. IN DWORD nBufferLength,
  1078. OUT LPWSTR lpBuffer
  1079. );
  1080. // GDI32.dll
  1081. int WINAPI
  1082. GetObjectWrapW( IN HGDIOBJ, IN int, OUT LPVOID);
  1083. BOOL
  1084. WINAPI
  1085. ExtTextOutWrapW(
  1086. HDC hdc,
  1087. int x,
  1088. int y,
  1089. UINT fl,
  1090. CONST RECT *prcl,
  1091. LPCWSTR pwsz,
  1092. UINT c, // count of bytes = 2 * (# of WCHAR's)
  1093. CONST INT *pdx);
  1094. BOOL
  1095. WINAPI
  1096. GetTextMetricsWrapW( IN HDC, OUT LPTEXTMETRICW);
  1097. HFONT
  1098. WINAPI
  1099. CreateFontIndirectWrapW( IN CONST LOGFONTW *);
  1100. BOOL
  1101. APIENTRY
  1102. GetTextExtentPointWrapW(HDC hdc,LPCWSTR pwsz,DWORD cwc,LPSIZE psizl);
  1103. HDC
  1104. WINAPI CreateMetaFileWrapW( IN LPCWSTR);
  1105. HDC
  1106. WINAPI CreateDCWrapW( IN LPCWSTR, IN LPCWSTR, IN LPCWSTR, IN CONST DEVMODEW *);
  1107. // USER32.dll
  1108. ULONG_PTR
  1109. WINAPI
  1110. SetClassLongPtrWrapW(
  1111. IN HWND hWnd,
  1112. IN int nIndex,
  1113. IN LONG_PTR dwNewLong);
  1114. HWND
  1115. WINAPI
  1116. CreateDialogIndirectParamWrapW(
  1117. IN HINSTANCE hInstance,
  1118. IN LPCDLGTEMPLATEW lpTemplate,
  1119. IN HWND hWndParent,
  1120. IN DLGPROC lpDialogFunc,
  1121. IN LPARAM dwInitParam);
  1122. LRESULT
  1123. WINAPI
  1124. DispatchMessageWrapW(
  1125. IN CONST MSG *lpMsg);
  1126. HWND
  1127. WINAPI
  1128. CreateDialogParamWrapW(
  1129. IN HINSTANCE hInstance,
  1130. IN LPCWSTR lpTemplateName,
  1131. IN HWND hWndParent,
  1132. IN DLGPROC lpDialogFunc,
  1133. IN LPARAM dwInitParam);
  1134. BOOL
  1135. WINAPI
  1136. IsDialogMessageWrapW(
  1137. IN HWND hDlg,
  1138. IN LPMSG lpMsg);
  1139. BOOL
  1140. WINAPI
  1141. SetDlgItemTextWrapW(
  1142. IN HWND hDlg,
  1143. IN int nIDDlgItem,
  1144. IN LPCWSTR lpString);
  1145. HANDLE
  1146. WINAPI
  1147. LoadImageWrapW(
  1148. IN HINSTANCE,
  1149. IN LPCWSTR,
  1150. IN UINT,
  1151. IN int,
  1152. IN int,
  1153. IN UINT);
  1154. UINT
  1155. WINAPI
  1156. GetDlgItemTextWrapW(
  1157. IN HWND hDlg,
  1158. IN int nIDDlgItem,
  1159. OUT LPWSTR lpString,
  1160. IN int nMaxCount);
  1161. LRESULT
  1162. WINAPI
  1163. SendDlgItemMessageWrapW(
  1164. IN HWND hDlg,
  1165. IN int nIDDlgItem,
  1166. IN UINT Msg,
  1167. IN WPARAM wParam,
  1168. IN LPARAM lParam);
  1169. int
  1170. WINAPI
  1171. TranslateAcceleratorWrapW(
  1172. IN HWND hWnd,
  1173. IN HACCEL hAccTable,
  1174. IN LPMSG lpMsg);
  1175. int
  1176. WINAPI
  1177. GetWindowTextWrapW(
  1178. IN HWND hWnd,
  1179. OUT LPWSTR lpString,
  1180. IN int nMaxCount);
  1181. INT_PTR
  1182. WINAPI
  1183. DialogBoxParamWrapW(
  1184. IN HINSTANCE hInstance,
  1185. IN LPCWSTR lpTemplateName,
  1186. IN HWND hWndParent,
  1187. IN DLGPROC lpDialogFunc,
  1188. IN LPARAM dwInitParam);
  1189. ATOM
  1190. WINAPI
  1191. RegisterClassExWrapW(
  1192. IN CONST WNDCLASSEXW *);
  1193. ATOM
  1194. WINAPI
  1195. RegisterClassWrapW(
  1196. IN CONST WNDCLASSW *lpWndClass);
  1197. BOOL
  1198. WINAPI
  1199. UnregisterClassWrapW(
  1200. IN LPCWSTR lpClassName,
  1201. IN HINSTANCE hInstance);
  1202. HICON
  1203. WINAPI
  1204. LoadIconWrapW(
  1205. IN HINSTANCE hInstance,
  1206. IN LPCWSTR lpIconName);
  1207. LONG
  1208. WINAPI
  1209. GetWindowLongWrapW(
  1210. IN HWND hWnd,
  1211. IN int nIndex);
  1212. LONG_PTR
  1213. WINAPI
  1214. GetWindowLongPtrWrapW(
  1215. HWND hWnd,
  1216. int nIndex);
  1217. HWND
  1218. WINAPI
  1219. CreateWindowExWrapW(
  1220. IN DWORD dwExStyle,
  1221. IN LPCWSTR lpClassName,
  1222. IN LPCWSTR lpWindowName,
  1223. IN DWORD dwStyle,
  1224. IN int X,
  1225. IN int Y,
  1226. IN int nWidth,
  1227. IN int nHeight,
  1228. IN HWND hWndParent,
  1229. IN HMENU hMenu,
  1230. IN HINSTANCE hInstance,
  1231. IN LPVOID lpParam);
  1232. BOOL
  1233. WINAPI
  1234. PostMessageWrapW(
  1235. IN HWND hWnd,
  1236. IN UINT Msg,
  1237. IN WPARAM wParam,
  1238. IN LPARAM lParam);
  1239. LONG
  1240. WINAPI
  1241. SetWindowLongWrapW(
  1242. IN HWND hWnd,
  1243. IN int nIndex,
  1244. IN LONG dwNewLong);
  1245. LONG_PTR
  1246. WINAPI
  1247. SetWindowLongPtrWrapW(
  1248. HWND hWnd,
  1249. int nIndex,
  1250. LONG_PTR dwNewLong);
  1251. LRESULT
  1252. WINAPI
  1253. SendMessageWrapW(
  1254. IN HWND hWnd,
  1255. IN UINT Msg,
  1256. IN WPARAM wParam,
  1257. IN LPARAM lParam);
  1258. BOOL
  1259. WINAPI
  1260. PeekMessageWrapW(
  1261. OUT LPMSG lpMsg,
  1262. IN HWND hWnd,
  1263. IN UINT wMsgFilterMin,
  1264. IN UINT wMsgFilterMax,
  1265. IN UINT wRemoveMsg);
  1266. UINT
  1267. WINAPI
  1268. MapVirtualKeyWrapW(
  1269. IN UINT uCode,
  1270. IN UINT uMapType);
  1271. HHOOK
  1272. WINAPI
  1273. SetWindowsHookExWrapW(
  1274. IN int idHook,
  1275. IN HOOKPROC lpfn,
  1276. IN HINSTANCE hmod,
  1277. IN DWORD dwThreadId);
  1278. BOOL
  1279. WINAPI
  1280. PostThreadMessageWrapW(
  1281. IN DWORD idThread,
  1282. IN UINT Msg,
  1283. IN WPARAM wParam,
  1284. IN LPARAM lParam);
  1285. BOOL
  1286. WINAPI
  1287. SetWindowTextWrapW(
  1288. IN HWND hWnd,
  1289. IN LPCWSTR lpString);
  1290. BOOL
  1291. WINAPI
  1292. WinHelpWrapW(
  1293. IN HWND hWndMain,
  1294. IN LPCWSTR lpszHelp,
  1295. IN UINT uCommand,
  1296. IN ULONG_PTR dwData
  1297. );
  1298. LRESULT
  1299. WINAPI
  1300. DefWindowProcWrapW(
  1301. IN HWND hWnd,
  1302. IN UINT Msg,
  1303. IN WPARAM wParam,
  1304. IN LPARAM lParam);
  1305. LRESULT
  1306. WINAPI
  1307. CallWindowProcWrapW(
  1308. IN WNDPROC lpPrevWndFunc,
  1309. IN HWND hWnd,
  1310. IN UINT Msg,
  1311. IN WPARAM wParam,
  1312. IN LPARAM lParam);
  1313. int
  1314. WINAPI
  1315. MessageBoxWrapW(
  1316. IN HWND hWnd,
  1317. IN LPCWSTR lpText,
  1318. IN LPCWSTR lpCaption,
  1319. IN UINT uType);
  1320. HCURSOR
  1321. WINAPI
  1322. LoadCursorWrapW(
  1323. IN HINSTANCE hInstance,
  1324. IN LPCWSTR lpCursorName);
  1325. BOOL
  1326. WINAPI
  1327. ModifyMenuWrapW(
  1328. IN HMENU hMnu,
  1329. IN UINT uPosition,
  1330. IN UINT uFlags,
  1331. IN UINT_PTR uIDNewItem,
  1332. IN LPCWSTR lpNewItem
  1333. );
  1334. BOOL
  1335. WINAPI
  1336. AppendMenuWrapW(
  1337. IN HMENU hMenu,
  1338. IN UINT uFlags,
  1339. IN UINT_PTR uIDNewItem,
  1340. IN LPCWSTR lpNewItem
  1341. );
  1342. int
  1343. WINAPI
  1344. LoadStringWrapW(
  1345. IN HINSTANCE hInstance,
  1346. IN UINT uID,
  1347. OUT LPWSTR lpBuffer,
  1348. IN int nBufferMax);
  1349. BOOL
  1350. WINAPI
  1351. GetMessageWrapW(
  1352. OUT LPMSG lpMsg,
  1353. IN HWND hWnd,
  1354. IN UINT wMsgFilterMin,
  1355. IN UINT wMsgFilterMax);
  1356. HACCEL
  1357. WINAPI
  1358. LoadAcceleratorsWrapW(
  1359. IN HINSTANCE hInstance,
  1360. IN LPCWSTR lpTableName);
  1361. LPWSTR
  1362. WINAPI
  1363. CharNextWrapW(
  1364. IN LPCWSTR lpsz);
  1365. BOOL WINAPI
  1366. InsertMenuWrapW(
  1367. HMENU hMenu,
  1368. UINT uPosition,
  1369. UINT uFlags,
  1370. UINT_PTR uIDNewItem,
  1371. LPCWSTR lpNewItem);
  1372. DWORD WINAPI
  1373. CharLowerBuffWrapW( LPWSTR pch, DWORD cchLength );
  1374. DWORD WINAPI
  1375. CharUpperBuffWrapW( LPWSTR pch, DWORD cchLength );
  1376. HWND WINAPI
  1377. FindWindowExWrapW(
  1378. HWND hwndParent,
  1379. HWND hwndChildAfter,
  1380. LPCWSTR pwzClassName,
  1381. LPCWSTR pwzWindowName);
  1382. BOOL WINAPI IsCharAlphaWrapW(IN WCHAR ch);
  1383. BOOL WINAPI IsCharUpperWrapW(IN WCHAR ch);
  1384. BOOL WINAPI IsCharLowerWrapW(IN WCHAR ch);
  1385. BOOL WINAPI IsCharAlphaNumericWrapW(IN WCHAR ch);
  1386. BOOL WINAPI
  1387. GetClassInfoWrapW(
  1388. HINSTANCE hModule,
  1389. LPCWSTR lpClassName,
  1390. LPWNDCLASSW lpWndClassW);
  1391. BOOL
  1392. WINAPI
  1393. GetClassInfoExWrapW(
  1394. IN HINSTANCE,
  1395. IN LPCWSTR,
  1396. OUT LPWNDCLASSEXW);
  1397. BOOL
  1398. WINAPI
  1399. GetKeyboardLayoutNameWrapW(
  1400. OUT LPWSTR pwszKLID);
  1401. int
  1402. WINAPI
  1403. GetClipboardFormatNameWrapW(
  1404. IN UINT format,
  1405. OUT LPWSTR lpszFormatName,
  1406. IN int cchMaxCount);
  1407. UINT
  1408. WINAPI
  1409. RegisterClipboardFormatWrapW(
  1410. IN LPCWSTR lpszFormat);
  1411. BOOL
  1412. WINAPI
  1413. GetComputerNameWrapW (
  1414. OUT LPWSTR lpBuffer,
  1415. IN OUT LPDWORD nSize
  1416. );
  1417. HANDLE
  1418. WINAPI
  1419. CreateSemaphoreWrapW(
  1420. IN LPSECURITY_ATTRIBUTES lpSemaphoreAttributes,
  1421. IN LONG lInitialCount,
  1422. IN LONG lMaximumCount,
  1423. IN LPCWSTR lpName
  1424. );
  1425. //Shell32.dll
  1426. BOOL
  1427. SHGetPathFromIDListWrapW(
  1428. LPCITEMIDLIST pidl,
  1429. LPWSTR pszPath);
  1430. int
  1431. SHFileOperationWrapW(
  1432. LPSHFILEOPSTRUCTW pFileOpW);
  1433. HICON
  1434. ExtractIconWrapW(
  1435. HINSTANCE hInst,
  1436. LPCWSTR lpszExeFileName,
  1437. UINT nIconIndex);
  1438. int WINAPIV wsprintfWrapW(
  1439. LPWSTR lpOut,
  1440. LPCWSTR lpFmt,
  1441. ...);
  1442. int wvsprintfWrapW(LPWSTR pwszOut,
  1443. LPCWSTR pwszFormat,
  1444. va_list arglist);
  1445. //Comdlg32.dll
  1446. BOOL
  1447. APIENTRY
  1448. GetSaveFileNameWrapW(LPOPENFILENAMEW);
  1449. SHORT
  1450. WINAPI
  1451. GetFileTitleWrapW(
  1452. LPCWSTR lpszFileW,
  1453. LPWSTR lpszTitleW,
  1454. WORD cbBuf);
  1455. BOOL
  1456. WINAPI
  1457. GetOpenFileNameWrapW(OPENFILENAME FAR*);
  1458. //Shell32.dll
  1459. STDAPI SHGetFolderPathWrapW(HWND hwnd, int csidl,
  1460. HANDLE hToken, DWORD dwFlags,
  1461. LPWSTR pszPath);
  1462. STDAPI StrRetToStrWrapW(STRRET *pstr,
  1463. LPCITEMIDLIST pidl,
  1464. LPWSTR *ppsz);
  1465. //winspool.lib
  1466. BOOL
  1467. WINAPI
  1468. EnumPrintersWrapW(
  1469. IN DWORD Flags,
  1470. IN LPWSTR Name,
  1471. IN DWORD Level,
  1472. OUT LPBYTE pPrinterEnum,
  1473. IN DWORD cbBuf,
  1474. OUT LPDWORD pcbNeeded,
  1475. OUT LPDWORD pcReturned
  1476. );
  1477. BOOL
  1478. WINAPI
  1479. OpenPrinterWrapW(
  1480. IN LPWSTR pPrinterName,
  1481. OUT LPHANDLE phPrinter,
  1482. IN LPPRINTER_DEFAULTSW pDefault
  1483. );
  1484. DWORD
  1485. WINAPI
  1486. StartDocPrinterWrapW(
  1487. IN HANDLE hPrinter,
  1488. IN DWORD Level,
  1489. IN LPBYTE pDocInfo
  1490. );
  1491. DWORD
  1492. WINAPI
  1493. GetPrinterDataWrapW(
  1494. IN HANDLE hPrinter,
  1495. IN LPWSTR pValueName,
  1496. OUT LPDWORD pType,
  1497. OUT LPBYTE pData,
  1498. IN DWORD nSize,
  1499. OUT LPDWORD pcbNeeded
  1500. );
  1501. BOOL
  1502. WINAPI
  1503. GetPrinterDriverWrapW(
  1504. HANDLE hPrinter, // printer object
  1505. LPTSTR pEnvironment, // environment name. NULL is supported.
  1506. DWORD Level, // information level
  1507. LPBYTE pDriverInfo, // driver data buffer
  1508. DWORD cbBuf, // size of buffer
  1509. LPDWORD pcbNeeded // bytes received or required
  1510. );
  1511. //
  1512. // IME Wrapper functions accept fn pointers to the entry points
  1513. // to the real functions since other modules will dynamically bind
  1514. //
  1515. typedef BOOL (CALLBACK* PFN_ImmGetIMEFileNameW)(
  1516. IN HKL hkl,
  1517. OUT LPWSTR lpszFileName,
  1518. OUT UINT uBufferLength
  1519. );
  1520. typedef BOOL (CALLBACK* PFN_ImmGetIMEFileNameA)(
  1521. IN HKL hkl,
  1522. OUT LPSTR lpszFileName,
  1523. OUT UINT uBufferLength
  1524. );
  1525. UINT ImmGetIMEFileName_DynWrapW(
  1526. IN HKL hkl,
  1527. OUT LPWSTR szName,
  1528. IN UINT uBufLen,
  1529. IN PFN_ImmGetIMEFileNameW pfnImmGetIMEFileNameW,
  1530. IN PFN_ImmGetIMEFileNameA pfnImmGetIMEFileNameA);
  1531. typedef BOOL (CALLBACK* PFN_IMPGetIMEW)(
  1532. IN HWND hWnd,
  1533. OUT LPIMEPROW lpImePro
  1534. );
  1535. typedef BOOL (CALLBACK* PFN_IMPGetIMEA)(
  1536. IN HWND hWnd,
  1537. OUT LPIMEPROA lpImePro
  1538. );
  1539. BOOL ImpGetIME_DynWrapW(
  1540. IN HWND hWnd,
  1541. OUT LPIMEPROW lpImeProW,
  1542. IN PFN_IMPGetIMEW pfnIMPGetIMEW,
  1543. IN PFN_IMPGetIMEA pfnIMPGetIMEA);
  1544. #ifdef __cplusplus
  1545. } //endif extern "C"
  1546. #endif
  1547. #endif //DEFINE_WRAPPER_FNS
  1548. #endif //defined(UNICODE) && !defined(_WIN64)
  1549. #endif //_uwrap_h_