Spinner: Don't change value when changing min/max options

Fixes #9703
Closes gh-1252
This commit is contained in:
David Petersen 2014-05-19 19:29:45 -05:00
parent 9a93a06fbd
commit 796a8b37e2
2 changed files with 3 additions and 4 deletions

View File

@ -122,7 +122,7 @@ test( "stop", function() {
});
asyncTest( "change", function() {
expect( 14 );
expect( 12 );
var element = $( "#spin" ).spinner();
function shouldChange( expectation, msg ) {
@ -239,13 +239,13 @@ asyncTest( "change", function() {
shouldChange( false, "value, same value" );
element.spinner( "value", 999 );
shouldChange( true, "max, value changed" );
shouldChange( false, "max, value not changed" );
element.spinner( "option", "max", 900 );
shouldChange( false, "max, value not changed" );
element.spinner( "option", "max", 1000 );
shouldChange( true, "min, value changed" );
shouldChange( false, "min, value not changed" );
element.spinner( "option", "min", 950 );
shouldChange( false, "min, value not changed" );

View File

@ -403,7 +403,6 @@ return $.widget( "ui.spinner", {
_setOptions: spinner_modifier(function( options ) {
this._super( options );
this._value( this.element.val() );
}),
_parse: function( val ) {