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
fedcd4bb
Commit
fedcd4bb
authored
Mar 14, 2024
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
Mar 14, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32/tests: Add more tests for IImageList2 interface.
Signed-off-by:
Dmitry Timoshkov
<
dmitry@baikal.ru
>
parent
3944b36b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
46 additions
and
1 deletion
+46
-1
imagelist.c
dlls/comctl32/tests/imagelist.c
+46
-1
No files found.
dlls/comctl32/tests/imagelist.c
View file @
fedcd4bb
...
...
@@ -1672,6 +1672,8 @@ static void test_iimagelist(void)
HIMAGELIST
himl
;
HRESULT
hr
;
ULONG
ret
;
HBITMAP
hbm
;
int
ret2
;
if
(
!
pHIMAGELIST_QueryInterface
)
{
...
...
@@ -1741,7 +1743,50 @@ static void test_iimagelist(void)
win_skip
(
"IImageList2 is not supported.
\n
"
);
return
;
}
ok
(
hr
==
S_OK
,
"got 0x%08lx
\n
"
,
hr
);
hr
=
IImageList2_Initialize
(
imagelist
,
BMP_CX
,
BMP_CX
,
ILC_COLOR24
,
1
,
1
);
todo_wine
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
if
(
hr
!=
S_OK
)
return
;
check_iml_data
((
HIMAGELIST
)
imagelist
,
BMP_CX
,
BMP_CX
,
0
,
2
,
1
,
ILC_COLOR24
,
"IImageList2 0"
);
hr
=
IImageList2_Remove
(
imagelist
,
0
);
ok
(
hr
==
E_INVALIDARG
,
"got %#lx
\n
"
,
hr
);
hr
=
IImageList2_Remove
(
imagelist
,
-
1
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
hbm
=
CreateBitmap
(
BMP_CX
,
BMP_CX
,
1
,
1
,
NULL
);
ret2
=
-
1
;
hr
=
IImageList2_Add
(
imagelist
,
hbm
,
0
,
&
ret2
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
ok
(
ret2
==
0
,
"got %d
\n
"
,
ret2
);
check_iml_data
((
HIMAGELIST
)
imagelist
,
BMP_CX
,
BMP_CX
,
1
,
2
,
4
,
ILC_COLOR24
,
"IImageList2 1"
);
ret2
=
-
1
;
hr
=
IImageList2_Add
(
imagelist
,
hbm
,
0
,
&
ret2
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
ok
(
ret2
==
1
,
"got %d
\n
"
,
ret2
);
check_iml_data
((
HIMAGELIST
)
imagelist
,
BMP_CX
,
BMP_CX
,
2
,
7
,
4
,
ILC_COLOR24
,
"IImageList2 2"
);
hr
=
IImageList2_Remove
(
imagelist
,
0
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
check_iml_data
((
HIMAGELIST
)
imagelist
,
BMP_CX
,
BMP_CX
,
1
,
7
,
4
,
ILC_COLOR24
,
"IImageList2 1"
);
hr
=
IImageList2_Remove
(
imagelist
,
-
1
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
check_iml_data
((
HIMAGELIST
)
imagelist
,
BMP_CX
,
BMP_CX
,
0
,
4
,
1
,
ILC_COLOR24
,
"IImageList2 0"
);
hr
=
IImageList2_Remove
(
imagelist
,
0
);
ok
(
hr
==
E_INVALIDARG
,
"got %#lx
\n
"
,
hr
);
DeleteObject
(
hbm
);
IImageList2_Release
(
imagelist
);
}
...
...
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