diff options
author | Felix Nagel <info@felixnagel.com> | 2013-03-19 19:59:31 +0100 |
---|---|---|
committer | Felix Nagel <info@felixnagel.com> | 2013-03-19 19:59:31 +0100 |
commit | 1ce8d87f8bee3b1ec8698e0e2b8ead726d0d4ca2 (patch) | |
tree | 77edf8d66ab74aa11b86c286ba2a528b4d3c36de /ui/jquery.ui.spinner.js | |
parent | 5a9a80f86cc7844e7357af834c61cc14431110d1 (diff) | |
parent | 1c1f7c6184ba6f6a13e93960ea77c293f9d4308e (diff) | |
download | jquery-ui-1ce8d87f8bee3b1ec8698e0e2b8ead726d0d4ca2.tar.gz jquery-ui-1ce8d87f8bee3b1ec8698e0e2b8ead726d0d4ca2.zip |
Merge branch 'master' into selectmenu
Diffstat (limited to 'ui/jquery.ui.spinner.js')
-rw-r--r-- | ui/jquery.ui.spinner.js | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/ui/jquery.ui.spinner.js b/ui/jquery.ui.spinner.js index 644b65239..c022413dc 100644 --- a/ui/jquery.ui.spinner.js +++ b/ui/jquery.ui.spinner.js @@ -381,13 +381,9 @@ $.widget( "ui.spinner", { this._super( key, value ); if ( key === "disabled" ) { - if ( value ) { - this.element.prop( "disabled", true ); - this.buttons.button( "disable" ); - } else { - this.element.prop( "disabled", false ); - this.buttons.button( "enable" ); - } + this.widget().toggleClass( "ui-state-disabled", !!value ); + this.element.prop( "disabled", !!value ); + this.buttons.button( value ? "disable" : "enable" ); } }, |