Avoid using wxClientDC to redraw grid lines

This only happens when changing whether/how the lines are drawn, so
there should be no performance issue with just repainting the window.
This commit is contained in:
Paul Cornett
2022-01-17 08:49:05 -08:00
parent 8cfdabd50d
commit 32eb4af061

View File

@@ -9091,21 +9091,14 @@ void wxGrid::RedrawGridLines()
if ( !ShouldRefresh() )
return;
if ( GridLinesEnabled() )
{
DrawAllGridLines();
}
else // remove the grid lines
{
m_gridWin->Refresh();
m_gridWin->Refresh();
if ( m_frozenColGridWin )
m_frozenColGridWin->Refresh();
if ( m_frozenRowGridWin )
m_frozenRowGridWin->Refresh();
if ( m_frozenCornerGridWin )
m_frozenCornerGridWin->Refresh();
}
if ( m_frozenColGridWin )
m_frozenColGridWin->Refresh();
if ( m_frozenRowGridWin )
m_frozenRowGridWin->Refresh();
if ( m_frozenCornerGridWin )
m_frozenCornerGridWin->Refresh();
}
void wxGrid::EnableGridLines( bool enable )