kernel32: Add stub implementation for EnumResourceLanguagesEx.

This commit is contained in:
Daniel Scharrer 2015-01-23 14:58:30 +01:00 committed by Alexandre Julliard
parent 59e3a851f2
commit 4d05cfe577
4 changed files with 58 additions and 10 deletions

View File

@ -1,7 +1,7 @@
@ stub AddDllDirectory
@ stdcall DisableThreadLibraryCalls(long) kernel32.DisableThreadLibraryCalls
@ stub EnumResourceLanguagesExA
@ stub EnumResourceLanguagesExW
@ stdcall EnumResourceLanguagesExA(long str str ptr long long long) kernel32.EnumResourceLanguagesExA
@ stdcall EnumResourceLanguagesExW(long wstr wstr ptr long long long) kernel32.EnumResourceLanguagesExW
@ stub EnumResourceNamesExA
@ stub EnumResourceNamesExW
@ stub EnumResourceTypesExA

View File

@ -323,6 +323,8 @@
@ stdcall EnumLanguageGroupLocalesA(ptr long long ptr)
@ stdcall EnumLanguageGroupLocalesW(ptr long long ptr)
@ stdcall EnumResourceLanguagesA(long str str ptr long)
@ stdcall EnumResourceLanguagesExA(long str str ptr long long long)
@ stdcall EnumResourceLanguagesExW(long wstr wstr ptr long long long)
@ stdcall EnumResourceLanguagesW(long wstr wstr ptr long)
@ stdcall EnumResourceNamesA(long str ptr long)
@ stdcall EnumResourceNamesW(long wstr ptr long)

View File

@ -437,10 +437,11 @@ done:
/**********************************************************************
* EnumResourceLanguagesA (KERNEL32.@)
* EnumResourceLanguagesExA (KERNEL32.@)
*/
BOOL WINAPI EnumResourceLanguagesA( HMODULE hmod, LPCSTR type, LPCSTR name,
ENUMRESLANGPROCA lpfun, LONG_PTR lparam )
BOOL WINAPI EnumResourceLanguagesExA( HMODULE hmod, LPCSTR type, LPCSTR name,
ENUMRESLANGPROCA lpfun, LONG_PTR lparam,
DWORD flags, LANGID lang )
{
int i;
BOOL ret = FALSE;
@ -450,7 +451,15 @@ BOOL WINAPI EnumResourceLanguagesA( HMODULE hmod, LPCSTR type, LPCSTR name,
const IMAGE_RESOURCE_DIRECTORY *basedir, *resdir;
const IMAGE_RESOURCE_DIRECTORY_ENTRY *et;
TRACE( "%p %s %s %p %lx\n", hmod, debugstr_a(type), debugstr_a(name), lpfun, lparam );
TRACE( "%p %s %s %p %lx %x %d\n", hmod, debugstr_a(type), debugstr_a(name),
lpfun, lparam, flags, lang );
if (flags & (RESOURCE_ENUM_MUI | RESOURCE_ENUM_MUI_SYSTEM | RESOURCE_ENUM_VALIDATE))
FIXME( "unimplemented flags: %x\n", flags );
if (!flags) flags = RESOURCE_ENUM_LN | RESOURCE_ENUM_MUI;
if (!(flags & RESOURCE_ENUM_LN)) return ret;
if (!hmod) hmod = GetModuleHandleA( NULL );
typeW.Buffer = nameW.Buffer = NULL;
@ -489,10 +498,21 @@ done:
/**********************************************************************
* EnumResourceLanguagesW (KERNEL32.@)
* EnumResourceLanguagesA (KERNEL32.@)
*/
BOOL WINAPI EnumResourceLanguagesW( HMODULE hmod, LPCWSTR type, LPCWSTR name,
ENUMRESLANGPROCW lpfun, LONG_PTR lparam )
BOOL WINAPI EnumResourceLanguagesA( HMODULE hmod, LPCSTR type, LPCSTR name,
ENUMRESLANGPROCA lpfun, LONG_PTR lparam )
{
return EnumResourceLanguagesExA( hmod, type, name, lpfun, lparam, 0, 0 );
}
/**********************************************************************
* EnumResourceLanguagesExW (KERNEL32.@)
*/
BOOL WINAPI EnumResourceLanguagesExW( HMODULE hmod, LPCWSTR type, LPCWSTR name,
ENUMRESLANGPROCW lpfun, LONG_PTR lparam,
DWORD flags, LANGID lang )
{
int i;
BOOL ret = FALSE;
@ -502,7 +522,15 @@ BOOL WINAPI EnumResourceLanguagesW( HMODULE hmod, LPCWSTR type, LPCWSTR name,
const IMAGE_RESOURCE_DIRECTORY *basedir, *resdir;
const IMAGE_RESOURCE_DIRECTORY_ENTRY *et;
TRACE( "%p %s %s %p %lx\n", hmod, debugstr_w(type), debugstr_w(name), lpfun, lparam );
TRACE( "%p %s %s %p %lx %x %d\n", hmod, debugstr_w(type), debugstr_w(name),
lpfun, lparam, flags, lang );
if (flags & (RESOURCE_ENUM_MUI | RESOURCE_ENUM_MUI_SYSTEM | RESOURCE_ENUM_VALIDATE))
FIXME( "unimplemented flags: %x\n", flags );
if (!flags) flags = RESOURCE_ENUM_LN | RESOURCE_ENUM_MUI;
if (!(flags & RESOURCE_ENUM_LN)) return ret;
if (!hmod) hmod = GetModuleHandleW( NULL );
typeW.Buffer = nameW.Buffer = NULL;
@ -540,6 +568,16 @@ done:
}
/**********************************************************************
* EnumResourceLanguagesW (KERNEL32.@)
*/
BOOL WINAPI EnumResourceLanguagesW( HMODULE hmod, LPCWSTR type, LPCWSTR name,
ENUMRESLANGPROCW lpfun, LONG_PTR lparam )
{
return EnumResourceLanguagesExW( hmod, type, name, lpfun, lparam, 0, 0 );
}
/**********************************************************************
* LoadResource (KERNEL32.@)
*/

View File

@ -1542,6 +1542,11 @@ typedef struct _REASON_CONTEXT
} Reason;
} REASON_CONTEXT, *PREASON_CONTEXT;
#define RESOURCE_ENUM_LN 0x0001
#define RESOURCE_ENUM_MUI 0x0002
#define RESOURCE_ENUM_MUI_SYSTEM 0x0004
#define RESOURCE_ENUM_VALIDATE 0x0008
WINBASEAPI BOOL WINAPI ActivateActCtx(HANDLE,ULONG_PTR *);
WINADVAPI BOOL WINAPI AddAccessAllowedAce(PACL,DWORD,DWORD,PSID);
WINADVAPI BOOL WINAPI AddAccessAllowedAceEx(PACL,DWORD,DWORD,DWORD,PSID);
@ -1749,6 +1754,9 @@ WINBASEAPI void WINAPI EnterCriticalSection(CRITICAL_SECTION *lpCrit);
WINBASEAPI BOOL WINAPI EnumResourceLanguagesA(HMODULE,LPCSTR,LPCSTR,ENUMRESLANGPROCA,LONG_PTR);
WINBASEAPI BOOL WINAPI EnumResourceLanguagesW(HMODULE,LPCWSTR,LPCWSTR,ENUMRESLANGPROCW,LONG_PTR);
#define EnumResourceLanguages WINELIB_NAME_AW(EnumResourceLanguages)
WINBASEAPI BOOL WINAPI EnumResourceLanguagesExA(HMODULE,LPCSTR,LPCSTR,ENUMRESLANGPROCA,LONG_PTR,DWORD,LANGID);
WINBASEAPI BOOL WINAPI EnumResourceLanguagesExW(HMODULE,LPCWSTR,LPCWSTR,ENUMRESLANGPROCW,LONG_PTR,DWORD,LANGID);
#define EnumResourceLanguagesEx WINELIB_NAME_AW(EnumResourceLanguagesEx)
WINBASEAPI BOOL WINAPI EnumResourceNamesA(HMODULE,LPCSTR,ENUMRESNAMEPROCA,LONG_PTR);
WINBASEAPI BOOL WINAPI EnumResourceNamesW(HMODULE,LPCWSTR,ENUMRESNAMEPROCW,LONG_PTR);
#define EnumResourceNames WINELIB_NAME_AW(EnumResourceNames)