diff options
author | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2015-09-21 13:04:08 +0200 |
---|---|---|
committer | Scott González <scott.gonzalez@gmail.com> | 2015-09-25 13:47:11 -0400 |
commit | 897dc718c61fdfe3c40c9a8b24c89128bbfe13aa (patch) | |
tree | b98c54c12c789966e3e1f48ea996ddc48e1f17e1 | |
parent | d2f62041f97f5cc31f191c4f5e155e336a035878 (diff) | |
download | jquery-ui-897dc718c61fdfe3c40c9a8b24c89128bbfe13aa.tar.gz jquery-ui-897dc718c61fdfe3c40c9a8b24c89128bbfe13aa.zip |
Slider: Remove redundant handling of disabled option on create
Ref #9151
Ref gh-1599
-rw-r--r-- | ui/widgets/slider.js | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/ui/widgets/slider.js b/ui/widgets/slider.js index 5c4f252d5..8b8a7292a 100644 --- a/ui/widgets/slider.js +++ b/ui/widgets/slider.js @@ -81,7 +81,6 @@ return $.widget( "ui.slider", $.ui.mouse, { "ui-widget ui-widget-content" ); this._refresh(); - this._setOption( "disabled", this.options.disabled ); this._animateOff = false; }, @@ -430,10 +429,6 @@ return $.widget( "ui.slider", $.ui.mouse, { valsLength = this.options.values.length; } - if ( key === "disabled" ) { - this._toggleClass( null, "ui-state-disabled", !!value ); - } - this._super( key, value ); switch ( key ) { @@ -481,6 +476,12 @@ return $.widget( "ui.slider", $.ui.mouse, { } }, + _setOptionDisabled: function( value ) { + this._super( value ); + + this._toggleClass( null, "ui-state-disabled", !!value ); + }, + //internal value getter // _value() returns value trimmed by min and max, aligned by step _value: function() { |