Slider: Improve destroy method

This commit is contained in:
jzaefferer 2010-10-26 12:53:34 +02:00
parent f667bb3c8d
commit 30d431b08a

View File

@ -331,17 +331,11 @@ $.widget('ui.spinner', {
}, },
destroy: function() { destroy: function() {
if ($.fn.mousewheel) {
this.element.unmousewheel();
}
this.element this.element
.removeClass('ui-spinner-input') .removeClass('ui-spinner-input')
.removeAttr('disabled') .removeAttr('disabled')
.removeAttr('autocomplete') .removeAttr('autocomplete');
.removeData('spinner') $.Widget.prototype.destroy.call( this );
.unbind(".spinner");
this.uiSpinner.replaceWith(this.element); this.uiSpinner.replaceWith(this.element);
}, },