X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/43bcf4c950478de9a6fe7ff9eaca4f5020230da2..f2ab8671bf5433eee5862bfa723feb54e4d63e9f:/contrib/src/gizmos/splittree.cpp diff --git a/contrib/src/gizmos/splittree.cpp b/contrib/src/gizmos/splittree.cpp index b7197607b5..a99b6733c8 100644 --- a/contrib/src/gizmos/splittree.cpp +++ b/contrib/src/gizmos/splittree.cpp @@ -338,7 +338,7 @@ void wxRemotelyScrolledTreeCtrl::OnScroll(wxScrollWinEvent& event) int orient = event.GetOrientation(); if (orient == wxHORIZONTAL) { - // Don't 'skip' or we'd get into infinite recursion + event.Skip(); return; } wxScrolledWindow* scrollWin = GetScrolledWindow(); @@ -427,7 +427,7 @@ void wxTreeCompanionWindow::OnPaint(wxPaintEvent& event) dc.DrawLine(0, cy, clientSize.x, cy); } } - if (m_treeCtrl->GetBoundingRect(lastH, itemRect)) + if (lastH.IsOk() && m_treeCtrl->GetBoundingRect(lastH, itemRect)) { cy = itemRect.GetBottom(); dc.DrawLine(0, cy, clientSize.x, cy); @@ -439,7 +439,7 @@ void wxTreeCompanionWindow::OnScroll(wxScrollWinEvent& event) int orient = event.GetOrientation(); if (orient == wxHORIZONTAL) { - // Don't 'skip' or we'd get into infinite recursion + event.Skip(); return; } if (!m_treeCtrl) @@ -585,8 +585,13 @@ void wxSplitterScrolledWindow::OnScroll(wxScrollWinEvent& event) if (orient == wxHORIZONTAL) { + inOnScroll = FALSE; + event.Skip(); + return; +#if 0 int newPos = m_xScrollPosition + nScrollInc; SetScrollPos(wxHORIZONTAL, newPos, TRUE ); +#endif } else {