diff options
author | Richard D. Worth <rdworth@gmail.com> | 2010-05-11 07:31:48 -0400 |
---|---|---|
committer | Richard D. Worth <rdworth@gmail.com> | 2010-05-11 07:31:48 -0400 |
commit | b7c0823da65254f420e4f8affefb4632ecad8f91 (patch) | |
tree | f344bec014438f9cbe7747f02ae46b31e4505fee /ui/jquery.ui.slider.js | |
parent | b53b48b61834fc09fdcd0e27e6f0d9aa5a2c1cd4 (diff) | |
download | jquery-ui-b7c0823da65254f420e4f8affefb4632ecad8f91.tar.gz jquery-ui-b7c0823da65254f420e4f8affefb4632ecad8f91.zip |
Slider: trim value to min and max when page_up or page_down is pressed. Fixed #5591 - Slider: can go below its defined minimum with PageDown
Diffstat (limited to 'ui/jquery.ui.slider.js')
-rw-r--r-- | ui/jquery.ui.slider.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ui/jquery.ui.slider.js b/ui/jquery.ui.slider.js index 440e75635..895b536c2 100644 --- a/ui/jquery.ui.slider.js +++ b/ui/jquery.ui.slider.js @@ -181,10 +181,10 @@ $.widget( "ui.slider", $.ui.mouse, { newVal = self._valueMax(); break; case $.ui.keyCode.PAGE_UP: - newVal = curVal + ( (self._valueMax() - self._valueMin()) / numPages ); + newVal = self._trimAlignValue( curVal + ( (self._valueMax() - self._valueMin()) / numPages ) ); break; case $.ui.keyCode.PAGE_DOWN: - newVal = curVal - ( (self._valueMax() - self._valueMin()) / numPages ); + newVal = self._trimAlignValue( curVal - ( (self._valueMax() - self._valueMin()) / numPages ) ); break; case $.ui.keyCode.UP: case $.ui.keyCode.RIGHT: |