[PATCH 3/4] Don't invalidate list on LVM_SETTEXTCOLOR

Nikolay Sivov nsivov at codeweavers.com
Wed Jul 20 07:04:08 CDT 2011


---
 dlls/comctl32/listview.c       |   13 ++++---------
 dlls/comctl32/tests/listview.c |    2 +-
 2 files changed, 5 insertions(+), 10 deletions(-)

diff --git a/dlls/comctl32/listview.c b/dlls/comctl32/listview.c
index f6eebe8..cbc6b24 100644
--- a/dlls/comctl32/listview.c
+++ b/dlls/comctl32/listview.c
@@ -8914,22 +8914,17 @@ static BOOL LISTVIEW_SetTextBkColor(LISTVIEW_INFO *infoPtr, COLORREF color)
  *
  * PARAMETER(S):
  * [I] infoPtr : valid pointer to the listview structure
- * [I] clrText : text color
+ * [I] color   : text color
  *
  * RETURN:
  *   SUCCESS : TRUE
  *   FAILURE : FALSE
  */
-static BOOL LISTVIEW_SetTextColor (LISTVIEW_INFO *infoPtr, COLORREF clrText)
+static BOOL LISTVIEW_SetTextColor (LISTVIEW_INFO *infoPtr, COLORREF color)
 {
-    TRACE("(clrText=%x)\n", clrText);
-
-    if (infoPtr->clrText != clrText)
-    {
-	infoPtr->clrText = clrText;
-	LISTVIEW_InvalidateList(infoPtr);
-    }
+    TRACE("(color=%x)\n", color);
 
+    infoPtr->clrText = color;
     return TRUE;
 }
 
diff --git a/dlls/comctl32/tests/listview.c b/dlls/comctl32/tests/listview.c
index e33e334..6617798 100644
--- a/dlls/comctl32/tests/listview.c
+++ b/dlls/comctl32/tests/listview.c
@@ -1803,7 +1803,7 @@ static void test_color(void)
     rect.right = rect.bottom = 1;
     r = GetUpdateRect(hwnd, &rect, TRUE);
     todo_wine expect(FALSE, r);
-    todo_wine ok(rect.right == 0 && rect.bottom == 0, "got update rectangle\n");
+    ok(rect.right == 0 && rect.bottom == 0, "got update rectangle\n");
 
     r = ValidateRect(hwnd, NULL);
     expect(TRUE, r);
-- 
1.5.6.5



--------------090002040708060303000807--



More information about the wine-patches mailing list