File tree Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Original file line number Diff line number Diff line change @@ -435,7 +435,7 @@ $.extend(Timepicker.prototype, {
435
435
436
436
for ( var l = o . millisecMin ; l <= millisecMax ; l += parseInt ( o . millisecGrid , 10 ) ) {
437
437
millisecGridSize ++ ;
438
- html += '<td>' + ( ( l < 10 ) ? '0' : '' ) + s + '</td>' ;
438
+ html += '<td>' + ( ( l < 10 ) ? '0' : '' ) + l + '</td>' ;
439
439
}
440
440
441
441
html += '</tr></table></div>' ;
@@ -640,8 +640,21 @@ $.extend(Timepicker.prototype, {
640
640
var sliderAccessArgs = this . _defaults . sliderAccessArgs ;
641
641
setTimeout ( function ( ) { // fix for inline mode
642
642
$tp . find ( '.ui-slider:visible' ) . sliderAccess ( sliderAccessArgs ) ;
643
+
644
+ // fix any grids since sliders are shorter
645
+ var sliderAccessWidth = $tp . find ( '.ui-slider-access:eq(0)' ) . outerWidth ( true ) ;
646
+ $tp . find ( 'table:visible' ) . each ( function ( ) {
647
+ var $g = $ ( this ) ,
648
+ oldWidth = $g . outerWidth ( ) ,
649
+ oldMarginLeft = $g . css ( 'marginLeft' ) . toString ( ) . replace ( '%' , '' ) ,
650
+ newWidth = oldWidth - sliderAccessWidth ,
651
+ newMarginLeft = ( ( oldMarginLeft * newWidth ) / oldWidth ) + '%' ;
652
+
653
+ $g . css ( { width : newWidth , marginLeft : newMarginLeft } ) ;
654
+ } ) ;
643
655
} , 0 ) ;
644
656
}
657
+ // end slideAccess integration
645
658
}
646
659
} ,
647
660
You can’t perform that action at this time.
0 commit comments