uxtheme: Assume imagecount to be 1 if unspecified.

This commit is contained in:
Mark Harmstone 2015-02-28 20:22:27 +00:00 committed by Alexandre Julliard
parent 4c6427d080
commit b12f73a591
1 changed files with 3 additions and 0 deletions

View File

@ -257,6 +257,9 @@ static HRESULT UXTHEME_LoadImage(HTHEME hTheme, HDC hdc, int iPartId, int iState
imagenum = max (min (imagecount, iStateId), 1) - 1;
GetObjectW(*hBmp, sizeof(bmp), &bmp);
if(imagecount < 1) imagecount = 1;
if(imagelayout == IL_VERTICAL) {
int height = bmp.bmHeight/imagecount;
bmpRect->left = 0;