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
0aa22f98
Commit
0aa22f98
authored
Aug 26, 2004
by
Robert Shearman
Committed by
Alexandre Julliard
Aug 26, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow image list tests to compile and run on old platforms.
parent
7ed44d52
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
9 deletions
+22
-9
imagelist.c
dlls/comctl32/tests/imagelist.c
+22
-9
No files found.
dlls/comctl32/tests/imagelist.c
View file @
0aa22f98
...
...
@@ -24,7 +24,9 @@
#include "wine/test.h"
HDC
desktopDC
;
static
typeof
(
ImageList_DrawIndirect
)
*
pImageList_DrawIndirect
=
NULL
;
static
HDC
desktopDC
;
static
HIMAGELIST
createImageList
(
cx
,
cy
)
{
...
...
@@ -233,6 +235,17 @@ static BOOL DoTest3(void)
HDC
hdc
;
HWND
hwndfortest
;
if
(
!
pImageList_DrawIndirect
)
{
HMODULE
hComCtl32
=
LoadLibraryA
(
"comctl32.dll"
);
pImageList_DrawIndirect
=
GetProcAddress
(
hComCtl32
,
"ImageList_DrawIndirect"
);
if
(
!
pImageList_DrawIndirect
)
{
trace
(
"ImageList_DrawIndirect not available, skipping test
\n
"
);
return
TRUE
;
}
}
hwndfortest
=
create_a_window
();
hdc
=
GetDC
(
hwndfortest
);
ok
(
hdc
!=
NULL
,
"couldn't get DC
\n
"
);
...
...
@@ -262,25 +275,25 @@ static BOOL DoTest3(void)
Rectangle
(
hdc
,
100
,
100
,
74
,
74
);
memset
(
&
imldp
,
0
,
sizeof
imldp
);
ok
(
!
ImageList_DrawIndirect
(
&
imldp
),
"zero data succeeded!"
);
ok
(
!
p
ImageList_DrawIndirect
(
&
imldp
),
"zero data succeeded!"
);
imldp
.
cbSize
=
sizeof
imldp
;
ok
(
!
ImageList_DrawIndirect
(
&
imldp
),
"zero hdc succeeded!"
);
ok
(
!
p
ImageList_DrawIndirect
(
&
imldp
),
"zero hdc succeeded!"
);
imldp
.
hdcDst
=
hdc
;
ok
(
!
ImageList_DrawIndirect
(
&
imldp
),
"zero himl succeeded!"
);
ok
(
!
p
ImageList_DrawIndirect
(
&
imldp
),
"zero himl succeeded!"
);
imldp
.
himl
=
himl
;
ok
(
ImageList_DrawIndirect
(
&
imldp
),
"should succeeded"
);
ok
(
p
ImageList_DrawIndirect
(
&
imldp
),
"should succeeded"
);
imldp
.
fStyle
=
SRCCOPY
;
imldp
.
rgbBk
=
CLR_DEFAULT
;
imldp
.
rgbFg
=
CLR_DEFAULT
;
imldp
.
y
=
100
;
imldp
.
x
=
100
;
ok
(
ImageList_DrawIndirect
(
&
imldp
),
"should succeeded"
);
ok
(
p
ImageList_DrawIndirect
(
&
imldp
),
"should succeeded"
);
imldp
.
i
++
;
ok
(
ImageList_DrawIndirect
(
&
imldp
),
"should succeeded"
);
ok
(
p
ImageList_DrawIndirect
(
&
imldp
),
"should succeeded"
);
imldp
.
i
++
;
ok
(
ImageList_DrawIndirect
(
&
imldp
),
"should succeeded"
);
ok
(
p
ImageList_DrawIndirect
(
&
imldp
),
"should succeeded"
);
imldp
.
i
++
;
ok
(
!
ImageList_DrawIndirect
(
&
imldp
),
"should fail"
);
ok
(
!
p
ImageList_DrawIndirect
(
&
imldp
),
"should fail"
);
/* remove three */
ok
(
ImageList_Remove
(
himl
,
0
),
"removing 1st bitmap"
);
...
...
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