use wxRendererNative::DrawItemSelectionRect() to draw wxVListBox items background unless selection background colour is explicitly set (patch 1650804)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44640 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2007-03-07 20:58:18 +00:00
parent c741d33feb
commit 041254895c
3 changed files with 60 additions and 28 deletions

View File

@@ -365,17 +365,6 @@ void wxHtmlListBox::OnDrawItem(wxDC& dc, const wxRect& rect, size_t n) const
wxHtmlRenderingInfo htmlRendInfo;
// draw the selected cell in selected state
if ( IsSelected(n) )
{
wxHtmlSelection htmlSel;
htmlSel.Set(wxPoint(0,0), cell, wxPoint(INT_MAX, INT_MAX), cell);
htmlRendInfo.SetSelection(&htmlSel);
if ( m_htmlRendStyle )
htmlRendInfo.SetStyle(m_htmlRendStyle);
htmlRendInfo.GetState().SetSelectionState(wxHTML_SEL_IN);
}
// note that we can't stop drawing exactly at the window boundary as then
// even the visible cells part could be not drawn, so always draw the
// entire cell