Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
6cc0b4e8
Commit
6cc0b4e8
authored
May 18, 2007
by
Hans Leidekker
Committed by
Alexandre Julliard
May 18, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
setupapi: Add a partial implementation for SetupScanFileQueue{A, W}.
parent
108288ec
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
75 additions
and
9 deletions
+75
-9
queue.c
dlls/setupapi/queue.c
+68
-9
setupapi.h
include/setupapi.h
+7
-0
No files found.
dlls/setupapi/queue.c
View file @
6cc0b4e8
...
...
@@ -216,6 +216,7 @@ UINT CALLBACK QUEUE_callback_WtoA( void *context, UINT notification,
case
SPFILENOTIFY_RENAMEERROR
:
case
SPFILENOTIFY_STARTCOPY
:
case
SPFILENOTIFY_ENDCOPY
:
case
SPFILENOTIFY_QUEUESCAN_EX
:
{
FILEPATHS_W
*
pathsW
=
(
FILEPATHS_W
*
)
param1
;
FILEPATHS_A
pathsA
;
...
...
@@ -249,8 +250,18 @@ UINT CALLBACK QUEUE_callback_WtoA( void *context, UINT notification,
}
break
;
case
SPFILENOTIFY_NEEDMEDIA
:
case
SPFILENOTIFY_QUEUESCAN
:
{
LPWSTR
targetW
=
(
LPWSTR
)
param1
;
LPSTR
target
=
strdupWtoA
(
targetW
);
ret
=
callback_ctx
->
orig_handler
(
callback_ctx
->
orig_context
,
notification
,
(
UINT_PTR
)
target
,
param2
);
HeapFree
(
GetProcessHeap
(),
0
,
target
);
}
break
;
case
SPFILENOTIFY_NEEDMEDIA
:
FIXME
(
"mapping for %d not implemented
\n
"
,
notification
);
case
SPFILENOTIFY_STARTQUEUE
:
case
SPFILENOTIFY_ENDQUEUE
:
...
...
@@ -1203,22 +1214,70 @@ BOOL WINAPI SetupCommitFileQueueW( HWND owner, HSPFILEQ handle, PSP_FILE_CALLBAC
/***********************************************************************
* SetupScanFileQueueA (SETUPAPI.@)
*/
BOOL
WINAPI
SetupScanFileQueueA
(
HSPFILEQ
queu
e
,
DWORD
flags
,
HWND
window
,
PSP_FILE_CALLBACK_A
callback
,
PVOID
context
,
PDWORD
result
)
BOOL
WINAPI
SetupScanFileQueueA
(
HSPFILEQ
handl
e
,
DWORD
flags
,
HWND
window
,
PSP_FILE_CALLBACK_A
handler
,
PVOID
context
,
PDWORD
result
)
{
FIXME
(
"stub
\n
"
);
return
FALSE
;
struct
callback_WtoA_context
ctx
;
TRACE
(
"%p %x %p %p %p %p
\n
"
,
handle
,
flags
,
window
,
handler
,
context
,
result
);
ctx
.
orig_context
=
context
;
ctx
.
orig_handler
=
handler
;
return
SetupScanFileQueueW
(
handle
,
flags
,
window
,
QUEUE_callback_WtoA
,
&
ctx
,
result
);
}
/***********************************************************************
* SetupScanFileQueueW (SETUPAPI.@)
*/
BOOL
WINAPI
SetupScanFileQueueW
(
HSPFILEQ
queu
e
,
DWORD
flags
,
HWND
window
,
PSP_FILE_CALLBACK_W
callback
,
PVOID
context
,
PDWORD
result
)
BOOL
WINAPI
SetupScanFileQueueW
(
HSPFILEQ
handl
e
,
DWORD
flags
,
HWND
window
,
PSP_FILE_CALLBACK_W
handler
,
PVOID
context
,
PDWORD
result
)
{
FIXME
(
"stub
\n
"
);
return
FALSE
;
struct
file_queue
*
queue
=
handle
;
struct
file_op
*
op
;
FILEPATHS_W
paths
;
UINT
notification
=
0
;
BOOL
ret
=
FALSE
;
TRACE
(
"%p %x %p %p %p %p
\n
"
,
handle
,
flags
,
window
,
handler
,
context
,
result
);
if
(
!
queue
->
copy_queue
.
count
)
return
TRUE
;
if
(
flags
&
SPQ_SCAN_USE_CALLBACK
)
notification
=
SPFILENOTIFY_QUEUESCAN
;
else
if
(
flags
&
SPQ_SCAN_USE_CALLBACKEX
)
notification
=
SPFILENOTIFY_QUEUESCAN_EX
;
if
(
flags
&
~
(
SPQ_SCAN_USE_CALLBACK
|
SPQ_SCAN_USE_CALLBACKEX
))
{
FIXME
(
"flags %x not fully implemented
\n
"
,
flags
);
}
paths
.
Source
=
paths
.
Target
=
NULL
;
for
(
op
=
queue
->
copy_queue
.
head
;
op
;
op
=
op
->
next
)
{
build_filepathsW
(
op
,
&
paths
);
switch
(
notification
)
{
case
SPFILENOTIFY_QUEUESCAN
:
/* FIXME: handle delay flag */
if
(
handler
(
context
,
notification
,
(
UINT_PTR
)
paths
.
Target
,
0
))
goto
done
;
break
;
case
SPFILENOTIFY_QUEUESCAN_EX
:
if
(
handler
(
context
,
notification
,
(
UINT_PTR
)
&
paths
,
0
))
goto
done
;
break
;
default:
ret
=
TRUE
;
goto
done
;
}
}
ret
=
TRUE
;
done:
if
(
result
)
*
result
=
0
;
HeapFree
(
GetProcessHeap
(),
0
,
(
void
*
)
paths
.
Source
);
HeapFree
(
GetProcessHeap
(),
0
,
(
void
*
)
paths
.
Target
);
return
ret
;
}
...
...
include/setupapi.h
View file @
6cc0b4e8
...
...
@@ -437,6 +437,13 @@ DECL_WINELIB_SETUPAPI_TYPE_AW(PSP_ORIGINAL_FILE_INFO)
#define SPOST_URL 2
#define SPOST_MAX 3
#define SPQ_SCAN_FILE_PRESENCE 0x00000001
#define SPQ_SCAN_FILE_VALIDITY 0x00000002
#define SPQ_SCAN_USE_CALLBACK 0x00000004
#define SPQ_SCAN_USE_CALLBACKEX 0x00000008
#define SPQ_SCAN_INFORM_USER 0x00000010
#define SPQ_SCAN_PRUNE_COPY_QUEUE 0x00000020
#define FLG_ADDREG_DELREG_BIT 0x00008000
#define FLG_ADDREG_BINVALUETYPE 0x00000001
#define FLG_ADDREG_NOCLOBBER 0x00000002
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment