From 7b1fd9e527b92bd779b1771cfa0705ab056199c1 Mon Sep 17 00:00:00 2001 From: Daniel Jelinski Date: Sat, 5 Jan 2013 16:09:48 +0100 Subject: [PATCH] comctl32/listview: Redraw items after insert/delete. --- dlls/comctl32/listview.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/dlls/comctl32/listview.c b/dlls/comctl32/listview.c index dfa8d6e71a6..f1ebd7eebfe 100644 --- a/dlls/comctl32/listview.c +++ b/dlls/comctl32/listview.c @@ -5621,9 +5621,8 @@ static void LISTVIEW_ScrollOnInsert(LISTVIEW_INFO *infoPtr, INT nItem, INT dir) TRACE("rcScroll=%s, dx=%d\n", wine_dbgstr_rect(&rcScroll), dir * infoPtr->nItemHeight); if (IntersectRect(&rcScroll, &rcScroll, &infoPtr->rcList)) { - TRACE("Scrolling rcScroll=%s, rcList=%s\n", wine_dbgstr_rect(&rcScroll), wine_dbgstr_rect(&infoPtr->rcList)); - ScrollWindowEx(infoPtr->hwndSelf, 0, dir * infoPtr->nItemHeight, - &rcScroll, &rcScroll, 0, 0, SW_ERASE | SW_INVALIDATE); + TRACE("Invalidating rcScroll=%s, rcList=%s\n", wine_dbgstr_rect(&rcScroll), wine_dbgstr_rect(&infoPtr->rcList)); + InvalidateRect(infoPtr->hwndSelf, &rcScroll, TRUE); } /* report has only that column, so we're done */ @@ -5636,8 +5635,7 @@ static void LISTVIEW_ScrollOnInsert(LISTVIEW_INFO *infoPtr, INT nItem, INT dir) rcScroll.bottom = nPerCol * infoPtr->nItemHeight; OffsetRect(&rcScroll, Origin.x, Origin.y); if (IntersectRect(&rcScroll, &rcScroll, &infoPtr->rcList)) - ScrollWindowEx(infoPtr->hwndSelf, 0, dir * infoPtr->nItemHeight, - &rcScroll, &rcScroll, 0, 0, SW_ERASE | SW_INVALIDATE); + InvalidateRect(infoPtr->hwndSelf, &rcScroll, TRUE); } /***