From c2569f41b10ee497c7dfeeb5c90f354f8d574274 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 28 May 2002 16:44:33 +0000 Subject: [PATCH] fixed icon drawing when they have different sizes (patch 554973) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15698 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/generic/listctrl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/generic/listctrl.cpp b/src/generic/listctrl.cpp index 28853c64c4..38a9a92ce0 100644 --- a/src/generic/listctrl.cpp +++ b/src/generic/listctrl.cpp @@ -1449,8 +1449,8 @@ void wxListLineData::SetPosition( int x, int y, if ( item->HasImage() ) { - m_gi->m_rectIcon.x = m_gi->m_rectAll.x + 4 - + (spacing - m_gi->m_rectIcon.width)/2; + m_gi->m_rectIcon.x = m_gi->m_rectAll.x + 4 + + (m_gi->m_rectAll.width - m_gi->m_rectIcon.width) / 2; m_gi->m_rectIcon.y = m_gi->m_rectAll.y + 4; } -- 2.50.0