fix to last custom draw fix: only leave space for the image in the first column
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37817 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -2420,13 +2420,17 @@ static void HandleSubItemPrepaint(LPNMLVCUSTOMDRAW pLVCD, HFONT hfont)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// notice that even if this item doesn't have any image, the list
|
// notice that even if this item doesn't have any image, the list
|
||||||
// control still leaves space for the image if the image list is not
|
// control still leaves space for the image in the first column if the
|
||||||
// empty (presumably so that items with and without images align?)
|
// image list is not empty (presumably so that items with and without
|
||||||
|
// images align?)
|
||||||
|
if ( it.iImage != -1 || it.iSubItem == 0 )
|
||||||
|
{
|
||||||
int wImage, hImage;
|
int wImage, hImage;
|
||||||
ImageList_GetIconSize(himl, &wImage, &hImage);
|
ImageList_GetIconSize(himl, &wImage, &hImage);
|
||||||
|
|
||||||
rc.left += wImage + 2;
|
rc.left += wImage + 2;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
::SetBkMode(hdc, TRANSPARENT);
|
::SetBkMode(hdc, TRANSPARENT);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user