X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e1d3601acaecd1c69c453b60610ba98f619bd383..d485bda109d5ef0fef36a3f737549e9b9f54baab:/src/common/checklstcmn.cpp diff --git a/src/common/checklstcmn.cpp b/src/common/checklstcmn.cpp index 6721038c15..fe451702a7 100644 --- a/src/common/checklstcmn.cpp +++ b/src/common/checklstcmn.cpp @@ -99,4 +99,22 @@ wxCONSTRUCTOR_4( wxCheckListBox, wxWindow*, Parent, wxWindowID, Id, \ wxPoint, Position, wxSize, Size ) +// ============================================================================ +// implementation +// ============================================================================ + +unsigned int wxCheckListBoxBase::GetCheckedItems(wxArrayInt& checkedItems) const +{ + unsigned int const numberOfItems = GetCount(); + + checkedItems.clear(); + for ( unsigned int i = 0; i < numberOfItems; ++i ) + { + if ( IsChecked(i) ) + checkedItems.push_back(i); + } + + return checkedItems.size(); +} + #endif