From a28882ab8bb5b47b4089d3c894b41ad4afcadcc6 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sun, 25 Nov 2012 23:18:20 +0000 Subject: [PATCH] Fix wxGenericListCtrl scrolling by not processing the events twice. Scrolling wxGenericListCtrl was broken since r72939 because its OnScroll() event handler explicitly called wxScrollHelper::HandleOnScroll() which was also called by the base class ProcessEvent(). Arguably, wxScrollHelper::ProcessEvent() should be updated to allow handling events directly like this by not processing it again if the event wasn't skipped but for now just do skip the event and let the default handling take place which at least makes wxGenericListCtrl work correctly again. Closes #14852. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73019 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/generic/listctrl.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/generic/listctrl.cpp b/src/generic/listctrl.cpp index 363cfa40f8..03e299d46a 100644 --- a/src/generic/listctrl.cpp +++ b/src/generic/listctrl.cpp @@ -4612,13 +4612,14 @@ void wxGenericListCtrl::OnScroll(wxScrollWinEvent& event) // the window the next time m_mainWin->ResetVisibleLinesRange(); - HandleOnScroll( event ); - if ( event.GetOrientation() == wxHORIZONTAL && HasHeader() ) { m_headerWin->Refresh(); m_headerWin->Update(); } + + // Let the window be scrolled as usual by the default handler. + event.Skip(); } void wxGenericListCtrl::SetSingleStyle( long style, bool add ) -- 2.45.2