Permissions UI

Among other things, fixes #482 and #450.
Same as before, jQuery UI enable/disable cannot be done selectively on the children of a DOM tree where the UI element was enabled.