Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
8d503428
Commit
8d503428
authored
Sep 08, 2011
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32/tests: Allow an approximate color match for the cursor contents.
parent
4a148115
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
+6
-4
cursoricon.c
dlls/user32/tests/cursoricon.c
+6
-4
No files found.
dlls/user32/tests/cursoricon.c
View file @
8d503428
...
...
@@ -1405,6 +1405,7 @@ static int check_cursor_data( HDC hdc, HCURSOR hCursor, void *data, int length)
BITMAPINFO
*
info
;
ICONINFO
iinfo
;
DWORD
ret
;
int
i
;
ret
=
GetIconInfo
(
hCursor
,
&
iinfo
);
ok
(
ret
,
"GetIconInfo() failed
\n
"
);
...
...
@@ -1430,10 +1431,11 @@ static int check_cursor_data( HDC hdc, HCURSOR hCursor, void *data, int length)
if
(
!
image
)
goto
cleanup
;
ret
=
GetDIBits
(
hdc
,
iinfo
.
hbmColor
,
0
,
32
,
image
,
info
,
DIB_RGB_COLORS
);
ok
(
ret
,
"GetDIBits() failed
\n
"
);
if
(
!
ret
)
goto
cleanup
;
ret
=
(
memcmp
(
image
,
data
,
length
)
==
0
);
ok
(
ret
,
"Expected 0x%x, actually 0x%x (first 4 bytes only)
\n
"
,
*
(
DWORD
*
)
data
,
*
(
DWORD
*
)
image
);
for
(
i
=
0
;
ret
&&
i
<
length
/
sizeof
(
COLORREF
);
i
++
)
{
ret
=
color_match
(
((
COLORREF
*
)
data
)[
i
],
((
COLORREF
*
)
image
)[
i
]
);
ok
(
ret
,
"%04x: Expected 0x%x, actually 0x%x
\n
"
,
i
,
((
COLORREF
*
)
data
)[
i
],
((
COLORREF
*
)
image
)[
i
]
);
}
cleanup:
HeapFree
(
GetProcessHeap
(),
0
,
image
);
HeapFree
(
GetProcessHeap
(),
0
,
info
);
...
...
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