1
0
Fork 0
forked from 0x2620/oxjs

fix a bug related to disabling checkboxes

This commit is contained in:
rlx 2011-10-27 11:20:00 +00:00
commit a4cb6ee9ae
2 changed files with 9 additions and 4 deletions

View file

@ -79,7 +79,9 @@ Ox.Checkbox = function(options, self) {
type: 'image'
})
.addClass('OxCheckbox')
.click(clickButton)
.bindEvent({
click: clickButton
})
.appendTo(that);
function clickButton() {
@ -102,7 +104,9 @@ Ox.Checkbox = function(options, self) {
if (key == 'checked') {
that.toggleChecked();
} else if (key == 'disabled') {
that.attr({disabled: value})
that.attr({disabled: value});
self.$button.options({disabled: value});
self.$title && self.$title.options({disabled: value});
} else if (key == 'title') {
self.$title.options({title: value});
}