MenuItem: handle disabled file items

This commit is contained in:
rolux 2012-06-27 12:54:46 +02:00
parent e72e68a1df
commit 4c6756c192

View file

@ -49,6 +49,9 @@ Ox.MenuItem = function(options, self) {
},
disabled: function() {
that.toggleClass('OxDisabled');
self.options.file && that.$button.options({
disabled: self.options.disabled
});
},
title: function() {
self.options.title = Ox.makeArray(self.options.title);
@ -93,6 +96,7 @@ Ox.MenuItem = function(options, self) {
self.options.file
?
that.$button = Ox.FileButton(Ox.extend({
disabled: self.options.disabled,
title: self.options.title[0]
}, self.options.file)).bindEvent({
click: function(data) {