]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/aui/auibar.h
Disallow drop downs on AUI check buttons.
[wxWidgets.git] / include / wx / aui / auibar.h
index 3e0439957f360926549ab6a9a5b039dc519aa2ce..a156877b27d0b00473bd0452ac5153e2f654be83 100644 (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; }