This fixes Rein's update problems in Newsbin Pro. Alexandre, I'll be away for 3h, you can commit the X-series at will. ChangeLog Do not invalidate list on WM_SETREDRAW Update size info even if redrawing is disabled Trivial cleanups, and some tracing. --- dlls/comctl32/listview.c.X11 Thu Oct 24 14:35:55 2002 +++ dlls/comctl32/listview.c Thu Oct 24 19:16:06 2002 @@ -1476,8 +1476,7 @@ UINT uView = infoPtr->dwStyle & LVS_TYPEMASK; SCROLLINFO horzInfo, vertInfo; - if (infoPtr->dwStyle & LVS_NOSCROLL) return; - if (!is_redrawing(infoPtr)) return; + if ((infoPtr->dwStyle & LVS_NOSCROLL) || !is_redrawing(infoPtr)) return; ZeroMemory(&horzInfo, sizeof(SCROLLINFO)); horzInfo.cbSize = sizeof(SCROLLINFO); @@ -4102,9 +4101,13 @@ rcScroll.right = rcScroll.left + infoPtr->nItemWidth; rcScroll.bottom = nPerCol * infoPtr->nItemHeight; OffsetRect(&rcScroll, Origin.x, Origin.y); + TRACE("rcScroll=%s, dx=%d\n", debugrect(&rcScroll), dir * infoPtr->nItemHeight); if (IntersectRect(&rcScroll, &rcScroll, &infoPtr->rcList)) + { + TRACE("Scrolling rcScroll=%s, rcList=%s\n", debugrect(&rcScroll), debugrect(&infoPtr->rcList)); ScrollWindowEx(infoPtr->hwndSelf, 0, dir * infoPtr->nItemHeight, &rcScroll, &rcScroll, 0, 0, SW_ERASE | SW_INVALIDATE); + } /* report has only that column, so we're done */ if (uView == LVS_REPORT) return; @@ -7739,7 +7742,6 @@ UINT uView = infoPtr->dwStyle & LVS_TYPEMASK; infoPtr->bFirstPaint = FALSE; - LISTVIEW_UpdateSize(infoPtr); LISTVIEW_UpdateItemSize(infoPtr); if (uView == LVS_ICON || uView == LVS_SMALLICON) LISTVIEW_Arrange(infoPtr, LVA_DEFAULT); @@ -7989,17 +7991,13 @@ */ static LRESULT LISTVIEW_SetRedraw(LISTVIEW_INFO *infoPtr, BOOL bRedraw) { - UINT uView = infoPtr->dwStyle & LVS_TYPEMASK; - infoPtr->bRedraw = bRedraw; if(!bRedraw) return 0; - LISTVIEW_UpdateSize(infoPtr); - if (uView == LVS_ICON || uView == LVS_SMALLICON) + if (is_autoarrange(infoPtr)) LISTVIEW_Arrange(infoPtr, LVA_DEFAULT); LISTVIEW_UpdateScroll(infoPtr); - LISTVIEW_InvalidateList(infoPtr); return 0; } @@ -8021,10 +8019,11 @@ { TRACE("(width=%d, height=%d)\n", Width, Height); + if (!LISTVIEW_UpdateSize(infoPtr)) return 0; + + /* do not bother with display related stuff if we're not redrawing */ if (!is_redrawing(infoPtr)) return 0; - if (!LISTVIEW_UpdateSize(infoPtr)) return 0; - if (is_autoarrange(infoPtr)) LISTVIEW_Arrange(infoPtr, LVA_DEFAULT); -- Dimi.