From cda21c8ddc3b96e2e7ec7955840bc2db34684d2d Mon Sep 17 00:00:00 2001 From: Marcos Date: Mon, 30 Nov 2020 09:22:13 -0300 Subject: [PATCH] Fix a cosmetic bug in ExtendRulesAndAlternateColour() code Ensure that vertical rules extend to the bottom of the window on the non-first page of the control too. This was probably broken in 5ae2a8ebb8 (Simplify API for extending wxListCtrl background display, 2020-11-09). Closes https://github.com/wxWidgets/wxWidgets/pull/2130 --- src/generic/listctrl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/generic/listctrl.cpp b/src/generic/listctrl.cpp index 6907d2fa9c..1440601279 100644 --- a/src/generic/listctrl.cpp +++ b/src/generic/listctrl.cpp @@ -2188,7 +2188,7 @@ void wxListMainWindow::OnPaint( wxPaintEvent &WXUNUSED(event) ) int x_pos = x - dev_x; if (col < GetColumnCount()-1) x_pos -= 2; - int ruleHeight = m_extendRulesAndAlternateColour + int ruleHeight = m_extendRulesAndAlternateColour && visibleEnd > visibleTo ? clientHeight : lastItemRect.GetBottom() + 1 - dev_y;