Menu: Update default visual test, remove the disable/toggle buttons, that behaviour must be covered by unit tests

This commit is contained in:
Jörn Zaefferer 2012-05-18 15:18:19 +02:00
parent 5fa6821897
commit c0873f5da9

View File

@ -18,8 +18,7 @@
top: 10
}).appendTo(document.body).themeswitcher();
function create() {
menus.menu({
$("#menu1, #menu2, #menu3, .menu4").menu({
select: function(event, ui) {
$("<div/>").text("Selected: " + ui.item.text()).appendTo("#log");
}
@ -38,20 +37,6 @@
},
menus: ".menuElement"
});
}
var menus = $("#menu1, #menu2, #menu3, .menu4"),
all = menus.add("#menu5, #menu6");
create();
$("#toggle-destroy").toggle(function() {
all.menu("destroy");
}, create);
$("#toggle-disable").toggle(function() {
all.menu("disable");
}, function() {
all.menu("enable");
});
});
</script>
<style>
@ -286,8 +271,5 @@
<div id="log" style="height: 400px; width: 300px; overflow: auto;" class="ui-widget-content"></div>
</div>
<button id="toggle-disable">Disable / Enable</button>
<button id="toggle-destroy">Destroy / Create</button>
</body>
</html>