X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c3f815fa63b5b3d253f8e27cc14d08a9cc901952..16c587ca765d00a17eb4fe83f6d94901a08801a4:/contrib/src/gizmos/splittree.cpp diff --git a/contrib/src/gizmos/splittree.cpp b/contrib/src/gizmos/splittree.cpp index 8a16309acf..87b3668ffd 100644 --- a/contrib/src/gizmos/splittree.cpp +++ b/contrib/src/gizmos/splittree.cpp @@ -298,20 +298,19 @@ void wxRemotelyScrolledTreeCtrl::OnPaint(wxPaintEvent& event) wxSize clientSize = GetClientSize(); wxRect itemRect; - int cy=0; wxTreeItemId h, lastH; for(h=GetFirstVisibleItem();h;h=GetNextVisible(h)) { if (GetBoundingRect(h, itemRect)) { - cy = itemRect.GetTop(); + int cy = itemRect.GetTop(); dc.DrawLine(0, cy, clientSize.x, cy); lastH = h; } } if (lastH.IsOk() && GetBoundingRect(lastH, itemRect)) { - cy = itemRect.GetBottom(); + int cy = itemRect.GetBottom(); dc.DrawLine(0, cy, clientSize.x, cy); } } @@ -508,13 +507,12 @@ void wxTreeCompanionWindow::OnPaint(wxPaintEvent& WXUNUSED(event)) wxSize clientSize = GetClientSize(); wxRect itemRect; - int cy=0; wxTreeItemId h, lastH; for(h=m_treeCtrl->GetFirstVisibleItem();h;h=m_treeCtrl->GetNextVisible(h)) { if (m_treeCtrl->GetBoundingRect(h, itemRect)) { - cy = itemRect.GetTop(); + int cy = itemRect.GetTop(); wxRect drawItemRect(0, cy, clientSize.x, itemRect.GetHeight()); lastH = h; @@ -526,7 +524,7 @@ void wxTreeCompanionWindow::OnPaint(wxPaintEvent& WXUNUSED(event)) } if (lastH.IsOk() && m_treeCtrl->GetBoundingRect(lastH, itemRect)) { - cy = itemRect.GetBottom(); + int cy = itemRect.GetBottom(); dc.DrawLine(0, cy, clientSize.x, cy); } }