From 603ad17064a4034426a7271998b6df1d674b5dfb Mon Sep 17 00:00:00 2001 From: Robert Roebling Date: Wed, 13 Sep 2000 20:02:41 +0000 Subject: [PATCH] wxListCtrl::InsertItem() returned number of items, not the new index. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_2_BRANCH@8355 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/generic/listctrl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/generic/listctrl.cpp b/src/generic/listctrl.cpp index 40cb90565f..ee9369a1de 100644 --- a/src/generic/listctrl.cpp +++ b/src/generic/listctrl.cpp @@ -2954,7 +2954,7 @@ void wxListMainWindow::InsertItem( wxListItem &item ) else { m_lines.Add( line ); - item.m_itemId = m_lines.GetCount(); + item.m_itemId = m_lines.GetCount()-1; } }