X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/11fa6e636b37ca8db5022dd9ad9502c37eac50fb..d154ab3d291c0c1463d77818f07fb8a5bfe6bfb0:/src/msw/renderer.cpp diff --git a/src/msw/renderer.cpp b/src/msw/renderer.cpp index b1a3c77ff6..285dfabbd1 100644 --- a/src/msw/renderer.cpp +++ b/src/msw/renderer.cpp @@ -534,7 +534,7 @@ wxRendererXP::DrawPushButton(wxWindow * win, } void -wxRendererXP::DrawItemSelectionRect(wxWindow * WXUNUSED(win), +wxRendererXP::DrawItemSelectionRect(wxWindow *win, wxDC& dc, const wxRect& rect, int flags) @@ -548,7 +548,7 @@ wxRendererXP::DrawItemSelectionRect(wxWindow * WXUNUSED(win), } else // !focused { - brush = wxBrush(wxSystemSettings::GetColour(wxSYS_COLOUR_BTNSHADOW)); + brush = wxBrush(wxSystemSettings::GetColour(wxSYS_COLOUR_BTNFACE)); } } else // !selected @@ -557,12 +557,11 @@ wxRendererXP::DrawItemSelectionRect(wxWindow * WXUNUSED(win), } dc.SetBrush(brush); - - // unlike for wxRendererGeneric, on windows we _never_ want to draw - // the outline of the rectangle: dc.SetPen(*wxTRANSPARENT_PEN); - dc.DrawRectangle( rect ); + + if ((flags & wxCONTROL_FOCUSED) && (flags & wxCONTROL_CURRENT)) + DrawFocusRect( win, dc, rect, flags ); }