X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c5ca409b6a6cc4ab503f5d81afa2f637ec609f4c..204e4cd6ee65758d39a89402a85ecd07ecf364f2:/src/msw/listctrl.cpp diff --git a/src/msw/listctrl.cpp b/src/msw/listctrl.cpp index e40225b1c0..f5cf108c8e 100644 --- a/src/msw/listctrl.cpp +++ b/src/msw/listctrl.cpp @@ -264,7 +264,7 @@ WX_END_FLAGS( wxListCtrlStyle ) IMPLEMENT_DYNAMIC_CLASS_XTI(wxListCtrl, wxControl,"wx/listctrl.h") WX_BEGIN_PROPERTIES_TABLE(wxListCtrl) - WX_DELEGATE( OnTextUpdated , wxEVT_COMMAND_TEXT_UPDATED , wxCommandEvent ) + WX_EVENT_PROPERTY( TextUpdated , wxEVT_COMMAND_TEXT_UPDATED , wxCommandEvent ) WX_PROPERTY_FLAGS( WindowStyle , wxListCtrlStyle , long , SetWindowStyleFlag , GetWindowStyleFlag , , 0 /*flags*/ , wxT("Helpstring") , wxT("group")) // style WX_END_PROPERTIES_TABLE() @@ -1506,16 +1506,17 @@ long wxListCtrl::InsertItem(wxListItem& info) if (info.m_mask & wxLIST_MASK_DATA) data->lParam = info.m_data; - // check whether it has any custom attributes - if ( info.HasAttributes() ) - { + // check whether it has any custom attributes + if ( info.HasAttributes() ) + { // take copy of attributes data->attr = new wxListItemAttr(*info.GetAttributes()); - } + } }; long rv = ListView_InsertItem(GetHwnd(), & item); - m_count += 1; + + m_count++; wxASSERT_MSG( m_count == ListView_GetItemCount(GetHwnd()), wxT("m_count should match ListView_GetItemCount"));