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
b7f2ccb6
Commit
b7f2ccb6
authored
Sep 09, 2009
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32: Use explicit prototypes for function pointers.
parent
b225082a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
9 deletions
+20
-9
comctl32undoc.c
dlls/comctl32/comctl32undoc.c
+20
-9
No files found.
dlls/comctl32/comctl32undoc.c
View file @
b7f2ccb6
...
...
@@ -206,6 +206,10 @@ DWORD WINAPI GetSize (LPVOID lpMem)
* - Free an MRU-list with FreeMRUList().
*/
typedef
INT
(
CALLBACK
*
MRUStringCmpFnA
)(
LPCSTR
lhs
,
LPCSTR
rhs
);
typedef
INT
(
CALLBACK
*
MRUStringCmpFnW
)(
LPCWSTR
lhs
,
LPCWSTR
rhs
);
typedef
INT
(
CALLBACK
*
MRUBinaryCmpFn
)(
LPCVOID
lhs
,
LPCVOID
rhs
,
DWORD
length
);
typedef
struct
tagCREATEMRULISTA
{
DWORD
cbSize
;
...
...
@@ -213,7 +217,11 @@ typedef struct tagCREATEMRULISTA
DWORD
dwFlags
;
HKEY
hKey
;
LPSTR
lpszSubKey
;
PROC
lpfnCompare
;
union
{
MRUStringCmpFnA
string_cmpfn
;
MRUBinaryCmpFn
binary_cmpfn
;
}
u
;
}
CREATEMRULISTA
,
*
LPCREATEMRULISTA
;
typedef
struct
tagCREATEMRULISTW
...
...
@@ -223,7 +231,11 @@ typedef struct tagCREATEMRULISTW
DWORD
dwFlags
;
HKEY
hKey
;
LPWSTR
lpszSubKey
;
PROC
lpfnCompare
;
union
{
MRUStringCmpFnW
string_cmpfn
;
MRUBinaryCmpFn
binary_cmpfn
;
}
u
;
}
CREATEMRULISTW
,
*
LPCREATEMRULISTW
;
/* dwFlags */
...
...
@@ -385,7 +397,7 @@ INT WINAPI FindMRUData (HANDLE hList, LPCVOID lpData, DWORD cbData,
UINT
i
;
LPSTR
dataA
=
NULL
;
if
(
!
mp
||
!
mp
->
extview
.
lpfnCompare
)
if
(
!
mp
||
!
mp
->
extview
.
u
.
string_cmpfn
)
return
-
1
;
if
(
!
(
mp
->
extview
.
dwFlags
&
MRUF_BINARY_LIST
)
&&
!
mp
->
isUnicode
)
{
...
...
@@ -397,13 +409,12 @@ INT WINAPI FindMRUData (HANDLE hList, LPCVOID lpData, DWORD cbData,
for
(
i
=
0
;
i
<
mp
->
cursize
;
i
++
)
{
if
(
mp
->
extview
.
dwFlags
&
MRUF_BINARY_LIST
)
{
if
(
!
mp
->
extview
.
lpfnCompare
(
lpData
,
&
mp
->
array
[
i
]
->
datastart
,
cbData
))
if
(
!
mp
->
extview
.
u
.
binary_cmpfn
(
lpData
,
&
mp
->
array
[
i
]
->
datastart
,
cbData
))
break
;
}
else
{
if
(
mp
->
isUnicode
)
{
if
(
!
mp
->
extview
.
lpfnCompare
(
lpData
,
&
mp
->
array
[
i
]
->
datastart
))
if
(
!
mp
->
extview
.
u
.
string_cmpfn
(
lpData
,
(
LPWSTR
)
&
mp
->
array
[
i
]
->
datastart
))
break
;
}
else
{
DWORD
len
=
WideCharToMultiByte
(
CP_ACP
,
0
,
...
...
@@ -414,7 +425,7 @@ INT WINAPI FindMRUData (HANDLE hList, LPCVOID lpData, DWORD cbData,
WideCharToMultiByte
(
CP_ACP
,
0
,
(
LPWSTR
)
&
mp
->
array
[
i
]
->
datastart
,
-
1
,
itemA
,
len
,
NULL
,
NULL
);
cmp
=
mp
->
extview
.
lpfnCompare
(
dataA
,
itemA
);
cmp
=
mp
->
extview
.
u
.
string_cmpfn
((
LPWSTR
)
dataA
,
(
LPWSTR
)
itemA
);
Free
(
itemA
);
if
(
!
cmp
)
break
;
...
...
@@ -672,7 +683,7 @@ static HANDLE CreateMRUListLazy_common(LPWINEMRULIST mp)
ERR
(
"(%u %u %x %p %s %p): Could not open key, error=%d
\n
"
,
mp
->
extview
.
cbSize
,
mp
->
extview
.
nMaxItems
,
mp
->
extview
.
dwFlags
,
mp
->
extview
.
hKey
,
debugstr_w
(
mp
->
extview
.
lpszSubKey
),
mp
->
extview
.
lpfnCompare
,
err
);
mp
->
extview
.
u
.
string_cmpfn
,
err
);
return
0
;
}
...
...
@@ -717,7 +728,7 @@ static HANDLE CreateMRUListLazy_common(LPWINEMRULIST mp)
TRACE
(
"(%u %u %x %p %s %p): Current Size = %d
\n
"
,
mp
->
extview
.
cbSize
,
mp
->
extview
.
nMaxItems
,
mp
->
extview
.
dwFlags
,
mp
->
extview
.
hKey
,
debugstr_w
(
mp
->
extview
.
lpszSubKey
),
mp
->
extview
.
lpfnCompare
,
mp
->
cursize
);
mp
->
extview
.
u
.
string_cmpfn
,
mp
->
cursize
);
return
mp
;
}
...
...
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