[PATCH 1/2] riched20: Don't call UpdateWindow after setting the background color.

Bruno Jesus 00cpxxx at gmail.com
Fri May 6 01:32:34 CDT 2016


On Fri, May 6, 2016 at 11:04 AM, Alex Henrie <alexhenrie24 at gmail.com> wrote:
> +static void test_background(void)
> +{
> +    HWND hwndRichEdit = new_richedit(NULL);
> +    RECT updateRect;
> +
> +    /* set the background color to black */
> +    ValidateRect(hwndRichEdit, NULL);
> +    SendMessageA(hwndRichEdit, EM_SETBKGNDCOLOR, FALSE, 0);
> +    GetUpdateRect(hwndRichEdit, &updateRect, FALSE);
> +    ok(!IsRectEmpty(&updateRect), "The update rect should not be empty\n");
> +
> +    DestroyWindow(hwndRichEdit);
> +}

I believe you should clear updateRect before calling GetUpdateRect,
also according to msdn the return value of GetUpdateRect should also
reflect if the rect was changed or not so it could be a double test.

Best wishes,
Bruno



More information about the wine-devel mailing list