Alexandre Julliard : shell32: Use a default icon for control panels without one.
Alexandre Julliard
julliard at winehq.org
Tue Jun 5 14:46:56 CDT 2012
Module: wine
Branch: master
Commit: c1e40a8bf49157020c6bc28c4f2ee0acb87bcaa4
URL: http://source.winehq.org/git/wine.git/?a=commit;h=c1e40a8bf49157020c6bc28c4f2ee0acb87bcaa4
Author: Alexandre Julliard <julliard at winehq.org>
Date: Tue Jun 5 19:54:23 2012 +0200
shell32: Use a default icon for control panels without one.
---
dlls/shell32/control.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/dlls/shell32/control.c b/dlls/shell32/control.c
index 988f249..6237894 100644
--- a/dlls/shell32/control.c
+++ b/dlls/shell32/control.c
@@ -301,8 +301,10 @@ static void Control_WndProc_Create(HWND hWnd, const CREATESTRUCTW* cs)
if (InsertMenuItemW(hSubMenu, menucount, TRUE, &mii)) {
/* add the list view item */
- index = ImageList_AddIcon(panel->hImageListLarge, applet->info[i].icon);
- ImageList_AddIcon(panel->hImageListSmall, applet->info[i].icon);
+ HICON icon = applet->info[i].icon;
+ if (!icon) icon = LoadImageW( 0, (LPCWSTR)IDI_WINLOGO, IMAGE_ICON, 0, 0, LR_SHARED );
+ index = ImageList_AddIcon(panel->hImageListLarge, icon);
+ ImageList_AddIcon(panel->hImageListSmall, icon);
lvItem.mask = LVIF_IMAGE | LVIF_TEXT | LVIF_PARAM;
lvItem.iItem = menucount;
More information about the wine-cvs
mailing list