mirror of
https://github.com/cemu-project/Cemu.git
synced 2025-08-24 07:11:52 +02:00
26 lines
1.1 KiB
Diff
26 lines
1.1 KiB
Diff
diff --git a/src/msw/listctrl.cpp b/src/msw/listctrl.cpp
|
|
index 2b9e0d7f7e..7eab8b37df 100644
|
|
--- a/src/msw/listctrl.cpp
|
|
+++ b/src/msw/listctrl.cpp
|
|
@@ -3110,6 +3110,11 @@ bool HandleSubItemPrepaint(wxListCtrl* listctrl, LPNMLVCUSTOMDRAW pLVCD, HFONT h
|
|
|
|
if ( it.iImage != -1 )
|
|
{
|
|
+ if ( !listctrl->HasCheckBoxes() )
|
|
+ {
|
|
+ rc.left -= 6;
|
|
+ }
|
|
+
|
|
const int yImage = rc.top + ((rc.bottom - rc.top) / 2 - hImage / 2);
|
|
ImageList_Draw(himl, it.iImage, hdc, rc.left, yImage,
|
|
nmcd.uItemState & CDIS_SELECTED ? ILD_SELECTED
|
|
@@ -3235,7 +3240,7 @@ void HandleItemPaint(wxListCtrl* listctrl, LPNMLVCUSTOMDRAW pLVCD, HFONT hfont)
|
|
// do not draw item background colour under the checkbox/image
|
|
RECT rcIcon;
|
|
wxGetListCtrlItemRect(nmcd.hdr.hwndFrom, nmcd.dwItemSpec, LVIR_ICON, rcIcon);
|
|
- if ( !::IsRectEmpty(&rcIcon) )
|
|
+ if ( !::IsRectEmpty(&rcIcon) && listctrl->HasCheckBoxes() )
|
|
rc.left = rcIcon.right + listctrl->FromDIP(GAP_BETWEEN_CHECKBOX_AND_TEXT);
|
|
}
|
|
|