[SHELL32] Implement ExtractIconResInfoA (#5846)

- Add ExtractIconResInfoA implementation.
- Add ExtractIconResInfo prototype to <undocshell.h>.
This commit is contained in:
Katayama Hirofumi MZ 2023-10-28 11:38:29 +09:00 committed by GitHub
parent 9dfb3e8e05
commit 81e936486e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 43 additions and 20 deletions

View file

@ -939,26 +939,12 @@ Printers_AddPrinterPropPages(LPVOID lpUnknown1, LPVOID lpUnknown2)
*/ */
EXTERN_C WORD EXTERN_C WORD
WINAPI WINAPI
ExtractIconResInfoA(HANDLE hHandle, ExtractIconResInfoW(
LPSTR lpFile, _In_ HANDLE hHandle,
WORD wIndex, _In_ LPCWSTR lpFileName,
LPWORD lpSize, _In_ WORD wIndex,
LPHANDLE lpIcon) _Out_ LPWORD lpSize,
{ _Out_ LPHANDLE lpIcon)
FIXME("ExtractIconResInfoA() stub\n");
return 0;
}
/*
* Unimplemented
*/
EXTERN_C WORD
WINAPI
ExtractIconResInfoW(HANDLE hHandle,
LPWSTR lpFile,
WORD wIndex,
LPWORD lpSize,
LPHANDLE lpIcon)
{ {
FIXME("ExtractIconResInfoW() stub\n"); FIXME("ExtractIconResInfoW() stub\n");
return 0; return 0;

View file

@ -65,6 +65,27 @@ PathIsSlowA(
return PathIsSlowW(strFileW, dwAttr); return PathIsSlowW(strFileW, dwAttr);
} }
/*************************************************************************
* ExtractIconResInfoA (SHELL32.221)
*/
EXTERN_C
WORD WINAPI
ExtractIconResInfoA(
_In_ HANDLE hHandle,
_In_ LPCSTR lpFileName,
_In_ WORD wIndex,
_Out_ LPWORD lpSize,
_Out_ LPHANDLE lpIcon)
{
TRACE("(%p, %s, %u, %p, %p)\n", hHandle, debugstr_a(lpFileName), wIndex, lpSize, lpIcon);
if (!lpFileName)
return 0;
CStringW strFileNameW(lpFileName);
return ExtractIconResInfoW(hHandle, strFileNameW, wIndex, lpSize, lpIcon);
}
/************************************************************************* /*************************************************************************
* SHOpenEffectiveToken (SHELL32.235) * SHOpenEffectiveToken (SHELL32.235)
*/ */

View file

@ -239,6 +239,22 @@ HICON WINAPI SHGetFileIcon(
BOOL WINAPI FileIconInit(BOOL bFullInit); BOOL WINAPI FileIconInit(BOOL bFullInit);
WORD WINAPI
ExtractIconResInfoA(
_In_ HANDLE hHandle,
_In_ LPCSTR lpFileName,
_In_ WORD wIndex,
_Out_ LPWORD lpSize,
_Out_ LPHANDLE lpIcon);
WORD WINAPI
ExtractIconResInfoW(
_In_ HANDLE hHandle,
_In_ LPCWSTR lpFileName,
_In_ WORD wIndex,
_Out_ LPWORD lpSize,
_Out_ LPHANDLE lpIcon);
/**************************************************************************** /****************************************************************************
* File Menu Routines * File Menu Routines
*/ */