Disallow drop downs on AUI check buttons.

This doesn't make much sense and disallowing it makes check items consistent
with radio ones as previously you could set up a dropdown for the former but
not for the latter.

Also update the documentation of the relevant methods.

Closes #14795.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72944 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin 2012-11-10 12:40:47 +00:00
parent 75b2220eba
commit 72ae0b5169
3 changed files with 56 additions and 38 deletions

View file

@ -211,7 +211,14 @@ public:
void SetActive(bool b) { m_active = b; }
bool IsActive() const { return m_active; }
void SetHasDropDown(bool b) { m_dropDown = b; }
void SetHasDropDown(bool b)
{
wxCHECK_RET( !b || m_kind == wxITEM_NORMAL,
wxS("Only normal tools can have drop downs") );
m_dropDown = b;
}
bool HasDropDown() const { return m_dropDown; }
void SetSticky(bool b) { m_sticky = b; }