Menu

#194 MenuItem::clearChildren does not seem to funciton

open
nobody
UI Related (10)
5
2008-09-27
2008-09-27
Fraggle
No

OS: Vista64

How to reproduce: in a beforeMenuPopup callback use the following code:

popupMenu_->getRootMenuItem()->clearChildren();
new DefaultMenuItem("I should be alone!", popupMenu_->getRootMenuItem(), popupMenu_);

Result: The menuItem "I should be alone" will appear along with any previously existing menuItems attached to that popupMenu, i.e. calling up the popupMenu again will result in there being two "I should be alone" entries in the menu.

Expected: All previous menuitems should be deleted by clearChildren().

Discussion


Log in to post a comment.

MongoDB Logo MongoDB