From c5b7bb59ec1c1a4326b58ce48e1feb76544bf414 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Fri, 12 Oct 2001 14:16:20 +0000 Subject: [PATCH] fix to avoid internal compiler error with gcc 2.95.2 on Alpha git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@11952 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/generic/listctrl.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/generic/listctrl.cpp b/src/generic/listctrl.cpp index c19161b5c2..69f4d47a54 100644 --- a/src/generic/listctrl.cpp +++ b/src/generic/listctrl.cpp @@ -1879,7 +1879,7 @@ void wxListHeaderWindow::OnPaint( wxPaintEvent &WXUNUSED(event) ) int numColumns = m_owner->GetColumnCount(); wxListItem item; - for (int i = 0; i < numColumns; i++) + for ( int i = 0; i < numColumns && x < w; i++ ) { m_owner->GetColumn( i, item ); int wCol = item.m_width; @@ -1923,11 +1923,9 @@ void wxListHeaderWindow::OnPaint( wxPaintEvent &WXUNUSED(event) ) dc.DrawText( item.GetText(), x + EXTRA_WIDTH, HEADER_OFFSET_Y + EXTRA_HEIGHT ); - if ( x > w - wCol + 5 ) - break; - x += wCol; } + dc.EndDrawing(); } -- 2.45.2