# HG changeset patch # User Sam Lantinga # Date 1234107306 0 # Node ID a434fe6360dfaec163584163d125ee140217d1f5 # Parent cd863dd2082bfd701bd1daf704fdb69cdb9bf10e Oh, Polyline() uses a pen, not a brush. Doh! :) diff -r cd863dd2082b -r a434fe6360df src/video/win32/SDL_gdirender.c --- a/src/video/win32/SDL_gdirender.c Sat Feb 07 18:03:46 2009 +0000 +++ b/src/video/win32/SDL_gdirender.c Sun Feb 08 15:35:06 2009 +0000 @@ -673,7 +673,7 @@ { GDI_RenderData *data = (GDI_RenderData *) renderer->driverdata; POINT points[2]; - HBRUSH brush; + HPEN pen; BOOL status; if (data->makedirty) { @@ -696,15 +696,15 @@ SDL_AddDirtyRect(&data->dirty, &rect); } - /* Should we cache the brushes? .. it looks like GDI does for us. :) */ - brush = CreateSolidBrush(RGB(renderer->r, renderer->g, renderer->b)); - SelectObject(data->current_hdc, brush); + /* Should we cache the pen? .. it looks like GDI does for us. :) */ + pen = CreatePen(PS_SOLID, 1, RGB(renderer->r, renderer->g, renderer->b)); + SelectObject(data->current_hdc, pen); points[0].x = x1; points[0].y = y1; points[1].x = x2; points[1].y = y2; status = Polyline(data->current_hdc, points, 2); - DeleteObject(brush); + DeleteObject(pen); if (!status) { WIN_SetError("FillRect()");