Menu: Added check for the disabled option on create.

This commit is contained in:
kborchers 2012-01-22 11:24:49 -06:00
parent 6800e1a2f9
commit 8c5c6e0a32

View File

@ -45,6 +45,9 @@ $.widget( "ui.menu", {
event.preventDefault();
}
}, this));
if ( this.options.disabled ) {
this.element.addClass( "ui-state-disabled" );
}
this._bind({
// Prevent focus from sticking to links inside menu after clicking
// them (focus should always stay on UL during navigation).