Proto.Menu - Prototype菜单插件


MIT
跨平台
JavaScript

软件简介

Proto.Menu 是一个基于 Prototype
开发的菜单组件。如下图所示:

示例代码:

var myLinks = [
{name: ‘Back’, callback: function(){alert(‘back function called’)}},
{name: ‘Forward’, callback: function(){alert(‘Forward function called’)}},
{separator: true},
{name: ‘Reload’, callback: function(){alert(‘Reload function called’)}},
{name: ‘Disabled option’, disabled: true},
{name: ‘Toggle previous option’, callback: function(){
var item = oLinks.find(function(l){return l.name == ‘Disabled option’});
item.disabled = item.disabled == false ? true : false;
}}
]