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
9db87f13
Commit
9db87f13
authored
Nov 16, 2009
by
Owen Rudge
Committed by
Alexandre Julliard
Nov 17, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shell32: Implement SHGetImageList and remove todo_wine from imagelist tests.
parent
c0a6c5cd
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
5 deletions
+37
-5
imagelist.c
dlls/comctl32/tests/imagelist.c
+3
-3
shellord.c
dlls/shell32/shellord.c
+34
-2
No files found.
dlls/comctl32/tests/imagelist.c
View file @
9db87f13
...
@@ -1012,18 +1012,18 @@ static void test_shell_imagelist(void)
...
@@ -1012,18 +1012,18 @@ static void test_shell_imagelist(void)
/* Get system image list */
/* Get system image list */
hr
=
(
pSHGetImageList
)(
SHIL_LARGE
,
&
IID_IImageList
,
(
void
**
)
&
iml
);
hr
=
(
pSHGetImageList
)(
SHIL_LARGE
,
&
IID_IImageList
,
(
void
**
)
&
iml
);
todo_wine
ok
(
SUCCEEDED
(
hr
),
"SHGetImageList failed, hr=%x
\n
"
,
hr
);
ok
(
SUCCEEDED
(
hr
),
"SHGetImageList failed, hr=%x
\n
"
,
hr
);
if
(
hr
!=
S_OK
)
if
(
hr
!=
S_OK
)
return
;
return
;
IImageList_GetImageCount
(
iml
,
&
out
);
IImageList_GetImageCount
(
iml
,
&
out
);
todo_wine
ok
(
out
>
0
,
"IImageList_GetImageCount returned out <= 0
\n
"
);
ok
(
out
>
0
,
"IImageList_GetImageCount returned out <= 0
\n
"
);
/* right and bottom should be 32x32 for large icons, or 48x48 if larger
/* right and bottom should be 32x32 for large icons, or 48x48 if larger
icons enabled in control panel */
icons enabled in control panel */
IImageList_GetImageRect
(
iml
,
0
,
&
rect
);
IImageList_GetImageRect
(
iml
,
0
,
&
rect
);
todo_wine
ok
((((
rect
.
right
==
32
)
&&
(
rect
.
bottom
==
32
))
||
ok
((((
rect
.
right
==
32
)
&&
(
rect
.
bottom
==
32
))
||
((
rect
.
right
==
48
)
&&
(
rect
.
bottom
==
48
))),
((
rect
.
right
==
48
)
&&
(
rect
.
bottom
==
48
))),
"IImageList_GetImageRect returned r:%d,b:%d
\n
"
,
"IImageList_GetImageRect returned r:%d,b:%d
\n
"
,
rect
.
right
,
rect
.
bottom
);
rect
.
right
,
rect
.
bottom
);
...
...
dlls/shell32/shellord.c
View file @
9db87f13
...
@@ -46,6 +46,7 @@
...
@@ -46,6 +46,7 @@
#include "pidl.h"
#include "pidl.h"
#include "shlwapi.h"
#include "shlwapi.h"
#include "commdlg.h"
#include "commdlg.h"
#include "commoncontrols.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
shell
);
WINE_DEFAULT_DEBUG_CHANNEL
(
shell
);
WINE_DECLARE_DEBUG_CHANNEL
(
pidl
);
WINE_DECLARE_DEBUG_CHANNEL
(
pidl
);
...
@@ -2173,10 +2174,41 @@ void WINAPI SHFlushSFCache(void)
...
@@ -2173,10 +2174,41 @@ void WINAPI SHFlushSFCache(void)
{
{
}
}
/*************************************************************************
* SHGetImageList (SHELL32.727)
*
* Returns a copy of a shell image list.
*
* NOTES
* Windows XP features 4 sizes of image list, and Vista 5. Wine currently
* only supports 2, so requests for the others will currently fail.
*/
HRESULT
WINAPI
SHGetImageList
(
int
iImageList
,
REFIID
riid
,
void
**
ppv
)
HRESULT
WINAPI
SHGetImageList
(
int
iImageList
,
REFIID
riid
,
void
**
ppv
)
{
{
FIXME
(
"STUB: %i %s
\n
"
,
iImageList
,
debugstr_guid
(
riid
));
HIMAGELIST
hLarge
,
hSmall
;
return
E_NOINTERFACE
;
HIMAGELIST
hNew
;
HRESULT
ret
=
E_FAIL
;
/* Wine currently only maintains large and small image lists */
if
((
iImageList
!=
SHIL_LARGE
)
&&
(
iImageList
!=
SHIL_SMALL
))
{
FIXME
(
"Unsupported image list %i requested
\n
"
,
iImageList
);
return
E_FAIL
;
}
Shell_GetImageList
(
&
hLarge
,
&
hSmall
);
hNew
=
ImageList_Duplicate
(
iImageList
==
SHIL_LARGE
?
hLarge
:
hSmall
);
/* Get the interface for the new image list */
if
(
hNew
)
{
ret
=
HIMAGELIST_QueryInterface
(
hNew
,
riid
,
ppv
);
if
(
!
SUCCEEDED
(
ret
))
ImageList_Destroy
(
hNew
);
}
return
ret
;
}
}
/*************************************************************************
/*************************************************************************
...
...
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