Propose for #3029 empty value not refreshing slider #3033

Closed
wants to merge 1 commit into
from
Jump to file or symbol
Failed to load files and symbols.
+3 −0
Split
@@ -270,6 +270,9 @@ $.widget( "mobile.slider", $.mobile.widget, {
if ( val == null ) {
val = cType === "input" ? parseFloat( control.val() ) : control[0].selectedIndex;
}
+ if ( isNaN( val ) ) {
+ val = 0;
+ }
percent = ( parseFloat( val ) - min ) / ( max - min ) * 100;
}