user32: Use a window's icon in preference to its class icon.

This commit is contained in:
Huw Davies 2007-03-16 14:53:16 +00:00 committed by Alexandre Julliard
parent 1c559eb474
commit 7a43e79087
1 changed files with 2 additions and 2 deletions

View File

@ -853,9 +853,9 @@ static BOOL MDI_AugmentFrameMenu( HWND frame, HWND hChild )
(LPCWSTR)HBMMENU_MBAR_CLOSE : (LPCWSTR)HBMMENU_MBAR_CLOSE_D );
/* The system menu is replaced by the child icon */
hIcon = (HICON)GetClassLongPtrW(hChild, GCLP_HICONSM);
hIcon = (HICON)SendMessageW(hChild, WM_GETICON, ICON_SMALL, 0);
if (!hIcon)
hIcon = (HICON)GetClassLongPtrW(hChild, GCLP_HICON);
hIcon = (HICON)SendMessageW(hChild, WM_GETICON, ICON_BIG, 0);
if (!hIcon)
hIcon = LoadImageW(0, MAKEINTRESOURCEW(IDI_WINLOGO), IMAGE_ICON, 0, 0, LR_DEFAULTCOLOR);
if (hIcon)