mirror of
git://source.winehq.org/git/wine.git
synced 2024-11-05 18:01:34 +00:00
setupapi: Implement SetupInstallFileExA/W.
This commit is contained in:
parent
2ec1e4a393
commit
bd9c265cc2
2 changed files with 33 additions and 13 deletions
|
@ -1063,17 +1063,17 @@ static BOOL do_file_copyW( LPCWSTR source, LPCWSTR target, DWORD style,
|
|||
}
|
||||
|
||||
/***********************************************************************
|
||||
* SetupInstallFileA (SETUPAPI.@)
|
||||
* SetupInstallFileExA (SETUPAPI.@)
|
||||
*/
|
||||
BOOL WINAPI SetupInstallFileA( HINF hinf, PINFCONTEXT inf_context, PCSTR source, PCSTR root,
|
||||
PCSTR dest, DWORD style, PSP_FILE_CALLBACK_A handler, PVOID context )
|
||||
BOOL WINAPI SetupInstallFileExA( HINF hinf, PINFCONTEXT inf_context, PCSTR source, PCSTR root,
|
||||
PCSTR dest, DWORD style, PSP_FILE_CALLBACK_A handler, PVOID context, PBOOL in_use )
|
||||
{
|
||||
BOOL ret = FALSE;
|
||||
struct callback_WtoA_context ctx;
|
||||
UNICODE_STRING sourceW, rootW, destW;
|
||||
|
||||
TRACE("%p %p %s %s %s %x %p %p\n", hinf, inf_context, debugstr_a(source), debugstr_a(root),
|
||||
debugstr_a(dest), style, handler, context);
|
||||
TRACE("%p %p %s %s %s %x %p %p %p\n", hinf, inf_context, debugstr_a(source), debugstr_a(root),
|
||||
debugstr_a(dest), style, handler, context, in_use);
|
||||
|
||||
sourceW.Buffer = rootW.Buffer = destW.Buffer = NULL;
|
||||
if (source && !RtlCreateUnicodeStringFromAsciiz( &sourceW, source ))
|
||||
|
@ -1095,7 +1095,7 @@ BOOL WINAPI SetupInstallFileA( HINF hinf, PINFCONTEXT inf_context, PCSTR source,
|
|||
ctx.orig_context = context;
|
||||
ctx.orig_handler = handler;
|
||||
|
||||
ret = SetupInstallFileW( hinf, inf_context, sourceW.Buffer, rootW.Buffer, destW.Buffer, style, QUEUE_callback_WtoA, &ctx );
|
||||
ret = SetupInstallFileExW( hinf, inf_context, sourceW.Buffer, rootW.Buffer, destW.Buffer, style, QUEUE_callback_WtoA, &ctx, in_use );
|
||||
|
||||
exit:
|
||||
RtlFreeUnicodeString( &sourceW );
|
||||
|
@ -1105,10 +1105,19 @@ exit:
|
|||
}
|
||||
|
||||
/***********************************************************************
|
||||
* SetupInstallFileW (SETUPAPI.@)
|
||||
* SetupInstallFileA (SETUPAPI.@)
|
||||
*/
|
||||
BOOL WINAPI SetupInstallFileW( HINF hinf, PINFCONTEXT inf_context, PCWSTR source, PCWSTR root,
|
||||
PCWSTR dest, DWORD style, PSP_FILE_CALLBACK_W handler, PVOID context )
|
||||
BOOL WINAPI SetupInstallFileA( HINF hinf, PINFCONTEXT inf_context, PCSTR source, PCSTR root,
|
||||
PCSTR dest, DWORD style, PSP_FILE_CALLBACK_A handler, PVOID context )
|
||||
{
|
||||
return SetupInstallFileExA( hinf, inf_context, source, root, dest, style, handler, context, NULL );
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* SetupInstallFileExW (SETUPAPI.@)
|
||||
*/
|
||||
BOOL WINAPI SetupInstallFileExW( HINF hinf, PINFCONTEXT inf_context, PCWSTR source, PCWSTR root,
|
||||
PCWSTR dest, DWORD style, PSP_FILE_CALLBACK_W handler, PVOID context, PBOOL in_use )
|
||||
{
|
||||
static const WCHAR CopyFiles[] = {'C','o','p','y','F','i','l','e','s',0};
|
||||
|
||||
|
@ -1116,8 +1125,10 @@ BOOL WINAPI SetupInstallFileW( HINF hinf, PINFCONTEXT inf_context, PCWSTR source
|
|||
WCHAR *buffer, *p, *inf_source = NULL;
|
||||
unsigned int len;
|
||||
|
||||
TRACE("%p %p %s %s %s %x %p %p\n", hinf, inf_context, debugstr_w(source), debugstr_w(root),
|
||||
debugstr_w(dest), style, handler, context);
|
||||
TRACE("%p %p %s %s %s %x %p %p %p\n", hinf, inf_context, debugstr_w(source), debugstr_w(root),
|
||||
debugstr_w(dest), style, handler, context, in_use);
|
||||
|
||||
if (in_use) FIXME("no file in use support\n");
|
||||
|
||||
if (hinf)
|
||||
{
|
||||
|
@ -1169,6 +1180,15 @@ BOOL WINAPI SetupInstallFileW( HINF hinf, PINFCONTEXT inf_context, PCWSTR source
|
|||
return ret;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* SetupInstallFileW (SETUPAPI.@)
|
||||
*/
|
||||
BOOL WINAPI SetupInstallFileW( HINF hinf, PINFCONTEXT inf_context, PCWSTR source, PCWSTR root,
|
||||
PCWSTR dest, DWORD style, PSP_FILE_CALLBACK_W handler, PVOID context )
|
||||
{
|
||||
return SetupInstallFileExW( hinf, inf_context, source, root, dest, style, handler, context, NULL );
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* SetupCommitFileQueueW (SETUPAPI.@)
|
||||
*/
|
||||
|
|
|
@ -437,8 +437,8 @@
|
|||
@ stdcall SetupInitializeFileLogA (str long)
|
||||
@ stdcall SetupInitializeFileLogW (wstr long)
|
||||
@ stdcall SetupInstallFileA(ptr ptr str str str long ptr ptr)
|
||||
@ stub SetupInstallFileExA
|
||||
@ stub SetupInstallFileExW
|
||||
@ stdcall SetupInstallFileExA(ptr ptr str str str long ptr ptr ptr)
|
||||
@ stdcall SetupInstallFileExW(ptr ptr wstr wstr wstr long ptr ptr ptr)
|
||||
@ stdcall SetupInstallFileW(ptr ptr wstr wstr wstr long ptr ptr)
|
||||
@ stdcall SetupInstallFilesFromInfSectionA(long long long str str long)
|
||||
@ stdcall SetupInstallFilesFromInfSectionW(long long long wstr wstr long)
|
||||
|
|
Loading…
Reference in a new issue