X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/52d2a5e4541626d86a501e137eeccc38ade3a283..86e9b8f28fc8db834628e1528e12f3eeb1f6e216:/src/generic/listctrl.cpp diff --git a/src/generic/listctrl.cpp b/src/generic/listctrl.cpp index a0a2e38aba..f8dc54fc71 100644 --- a/src/generic/listctrl.cpp +++ b/src/generic/listctrl.cpp @@ -24,7 +24,6 @@ #if wxUSE_LISTCTRL #include "wx/listctrl.h" -#include "wx/generic/private/listctrl.h" #if ((!defined(__WXMSW__) && !(defined(__WXMAC__) && wxOSX_USE_CARBON)) || defined(__WXUNIVERSAL__)) // if we have a native version, its implementation file does all this @@ -49,6 +48,7 @@ #include "wx/imaglist.h" #include "wx/renderer.h" +#include "wx/generic/private/listctrl.h" #ifdef __WXMAC__ #include "wx/osx/private.h" @@ -2577,8 +2577,8 @@ void wxListMainWindow::MoveToItem(size_t item) const int hLine = GetLineHeight(); - int view_x = SCROLL_UNIT_X * GetScrollPos( wxHORIZONTAL ); - int view_y = hLine * GetScrollPos( wxVERTICAL ); + int view_x = SCROLL_UNIT_X * GetListCtrl()->GetScrollPos( wxHORIZONTAL ); + int view_y = hLine * GetListCtrl()->GetScrollPos( wxVERTICAL ); if ( InReportView() ) { @@ -4216,7 +4216,7 @@ void wxListMainWindow::GetVisibleLinesRange(size_t *from, size_t *to) size_t count = GetItemCount(); if ( count ) { - m_lineFrom = GetScrollPos(wxVERTICAL); + m_lineFrom = GetListCtrl()->GetScrollPos(wxVERTICAL); // this may happen if SetScrollbars() hadn't been called yet if ( m_lineFrom >= count )