Listview fix
Dimitrie O. Paun
dpaun at rogers.com
Sun May 25 23:43:29 CDT 2003
We were avoiding any sort of display work until the
first paint message. This failed to work when items
where just inserted, as nothing would invalidate the
control. I think we can live without it.
With help from Maxime Bellengé.
ChangeLog
Remove this funky optimization, it is causing too much grief.
Index: dlls/comctl32/listview.c
===================================================================
RCS file: /var/cvs/wine/dlls/comctl32/listview.c,v
retrieving revision 1.353
diff -u -r1.353 listview.c
--- dlls/comctl32/listview.c 22 May 2003 03:37:10 -0000 1.353
+++ dlls/comctl32/listview.c 26 May 2003 04:38:49 -0000
@@ -250,7 +250,6 @@
INT ntmHeight; /* Some cached metrics of the font used */
INT ntmAveCharWidth; /* by the listview to draw items */
BOOL bRedraw; /* Turns on/off repaints & invalidations */
- BOOL bFirstPaint; /* Flags if the control has never painted before */
BOOL bAutoarrange; /* Autoarrange flag when NOT in LVS_AUTOARRANGE */
BOOL bFocus;
BOOL bDoChangeNotify; /* send change notification messages? */
@@ -1315,7 +1314,7 @@
static inline BOOL is_redrawing(LISTVIEW_INFO *infoPtr)
{
- return infoPtr->bRedraw && !infoPtr->bFirstPaint;
+ return infoPtr->bRedraw;
}
static inline void LISTVIEW_InvalidateRect(LISTVIEW_INFO *infoPtr, const RECT* rect)
@@ -7162,7 +7161,6 @@
infoPtr->nSelectionMark = -1;
infoPtr->nHotItem = -1;
infoPtr->bRedraw = TRUE;
- infoPtr->bFirstPaint = TRUE;
infoPtr->bNoItemMetrics = TRUE;
infoPtr->bDoChangeNotify = TRUE;
infoPtr->iconSpacing.cx = GetSystemMetrics(SM_CXICONSPACING);
@@ -7984,7 +7982,6 @@
{
TRACE("(hdc=%p)\n", hdc);
- infoPtr->bFirstPaint = FALSE;
if (infoPtr->bNoItemMetrics && infoPtr->nItemCount)
{
UINT uView = infoPtr->dwStyle & LVS_TYPEMASK;
--
Dimi.
More information about the wine-patches
mailing list