Add wxSelectionStore::IsEmpty() helper.

Just a simple and potentially (although not right now) more efficient
equivalent to GetSelectedCount() == 0.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77903 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2014-09-27 20:46:18 +00:00
parent d058c09e9f
commit 06ab4da3f3
2 changed files with 12 additions and 0 deletions

View File

@@ -71,6 +71,13 @@ public:
// return true if the given item is selected
bool IsSelected(unsigned item) const;
// return true if no items are currently selected
bool IsEmpty() const
{
return m_defaultState ? m_itemsSel.size() == m_count
: m_itemsSel.empty();
}
// return the total number of selected items
unsigned GetSelectedCount() const
{