I have a firefox Options extension panel where I have to dynamically create menu items and select a specific item for the current one.
here is the part of the xul file
<menulist id="rss_service_combo">
<menupopup id="rss_service_menu"/>
</menulist>
Then, in loadthe pref panel event , using js, add the menuitemelements to menupop. This is working fine. The only problem is that even if I set the item selected, the item is not selected, and the combo box is initially empty.
The only way that works at the moment is to manually add those menuitemto the XUL file and set the attribute selected, but I need to do this dynamically.
source
share