diff options
Diffstat (limited to 'ui/widgets/progressbar.js')
-rw-r--r-- | ui/widgets/progressbar.js | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/ui/widgets/progressbar.js b/ui/widgets/progressbar.js index b2c7259ba..7e2695994 100644 --- a/ui/widgets/progressbar.js +++ b/ui/widgets/progressbar.js @@ -117,13 +117,16 @@ return $.widget( "ui.progressbar", { // Don't allow a max less than min value = Math.max( this.min, value ); } - if ( key === "disabled" ) { - this.element.attr( "aria-disabled", value ); - this._toggleClass( null, "ui-state-disabled", !!value ); - } this._super( key, value ); }, + _setOptionDisabled: function( value ) { + this._super( value ); + + this.element.attr( "aria-disabled", value ); + this._toggleClass( null, "ui-state-disabled", !!value ); + }, + _percentage: function() { return this.indeterminate ? 100 : 100 * ( this.options.value - this.min ) / ( this.options.max - this.min ); }, |