# PopupMenu::containsAnyActiveItems() also counts section headers and separators

**URL:** <https://forum.juce.com/t/popupmenu-containsanyactiveitems-also-counts-section-headers-and-separators/37287>\
**Category:** General JUCE discussion\
**Created:** [January 23, 2020, 10:09am UTC](https://forum.juce.com/t/popupmenu-containsanyactiveitems-also-counts-section-headers-and-separators/37287 "2020-01-23T10:09:20Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![stijnfrishert](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/stijnfrishert/32/15727_2.png) [@stijnfrishert](https://forum.juce.com/u/stijnfrishert)\
**Post date:** [January 23, 2020, 10:09am UTC](https://forum.juce.com/t/popupmenu-containsanyactiveitems-also-counts-section-headers-and-separators/37287/1 "2020-01-23T10:09:20Z")

</div>

`PopupMenu::containsAnyActiveItems()` has the following description:

> Returns true if the menu contains any items that can be used.

That means that a menu that just contains separators and/or section headers, both of which can not actually be used, should return 0. The implementation of this function however, does not take that into account. Seems like a bug, right?

On a sidenote, submenu’s containing just separators/section headers also appear as active, but seems to me those should be greyed out as well. I’m assuming that code also uses `containsAnyActiveItems()`?
