sailingsumo / dat-gui

Automatically exported from code.google.com/p/dat-gui
0 stars 0 forks source link

Support for menu item hiding and radio buttons #18

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
For a web application I am creating, I required functionality for hiding and 
showing menu items within a folder. I looked through the code and couldn't find 
any implementation for this, so I ended up using the following code:

function toggleMenuItem(item, visible) {
    item.__li.style.display = visible ? "" : "none";
}

function isMenuItemVisible(item) {
    return item.__li.style.display != "none";
}

It works, but I wish it were included in the source.
In addition, there seems to be no support for radio buttons. Those would be 
nice.

Original issue reported on code.google.com by brian.clanton on 19 Jun 2012 at 3:36