The closest thing I can think of would be to use this :
And instead of building the menu statically, build it dynamically with the list of openend listers.
Bits of CycleListers could be reused, or ones from SwitchLister :
EDIT : This is not a dynamic button exactly, but kind of acts like it.