[0.4.15][COMCTL32] ListView LVIS_CUT image does not depend on focus (#7724)

Fixes CORE-19533. Also undoes flicker caused by PR #4218.
This commit is contained in:
Whindmar Saksit 2025-02-19 15:26:49 +01:00 committed by Carl J. Bialorucki
parent b5c1fdc1cc
commit 1acaa988bc

View file

@ -2270,11 +2270,7 @@ static void LISTVIEW_InvalidateSelectedItems(const LISTVIEW_INFO *infoPtr)
iterator_frameditems(&i, infoPtr, &infoPtr->rcList); iterator_frameditems(&i, infoPtr, &infoPtr->rcList);
while(iterator_next(&i)) while(iterator_next(&i))
{ {
#ifdef __REACTOS__
if (LISTVIEW_GetItemState(infoPtr, i.nItem, LVIS_SELECTED | LVIS_CUT))
#else
if (LISTVIEW_GetItemState(infoPtr, i.nItem, LVIS_SELECTED)) if (LISTVIEW_GetItemState(infoPtr, i.nItem, LVIS_SELECTED))
#endif
LISTVIEW_InvalidateItem(infoPtr, i.nItem); LISTVIEW_InvalidateItem(infoPtr, i.nItem);
} }
iterator_destroy(&i); iterator_destroy(&i);
@ -4782,7 +4778,11 @@ static void LISTVIEW_DrawItemPart(LISTVIEW_INFO *infoPtr, LVITEMW *item, const N
TRACE("iImage=%d\n", item->iImage); TRACE("iImage=%d\n", item->iImage);
#ifdef __REACTOS__
if (item->state & (LVIS_CUT | (infoPtr->bFocus ? LVIS_SELECTED : 0)))
#else
if (item->state & (LVIS_SELECTED | LVIS_CUT) && infoPtr->bFocus) if (item->state & (LVIS_SELECTED | LVIS_CUT) && infoPtr->bFocus)
#endif
style = ILD_SELECTED; style = ILD_SELECTED;
else else
style = ILD_NORMAL; style = ILD_NORMAL;