Implement wxListBox::GetSelections() in wxQt

This commit is contained in:
Liam Treacy
2018-12-06 14:42:50 +00:00
committed by Vadim Zeitlin
parent fd8248762e
commit 1f0e456620

View File

@@ -135,9 +135,17 @@ bool wxListBox::IsSelected(int n) const
return item->isSelected();
}
int wxListBox::GetSelections(wxArrayInt& WXUNUSED(aSelections)) const
int wxListBox::GetSelections(wxArrayInt& aSelections) const
{
return 0;
aSelections.clear();
for ( unsigned int i = 0; i < GetCount(); ++i)
{
if ( IsSelected(i) )
aSelections.push_back(i);
}
return aSelections.size();
}
unsigned wxListBox::GetCount() const