diff options
author | Andrew Powell <powella@gmail.com> | 2009-04-19 23:50:48 +0000 |
---|---|---|
committer | Andrew Powell <powella@gmail.com> | 2009-04-19 23:50:48 +0000 |
commit | 30ad5339489749be823757055aefa8311bd598d6 (patch) | |
tree | c9a8a225abcc1ba6577a7a2d1869e6557aeb2441 /ui/ui.slider.js | |
parent | dc76df3d07b57a486ad672fdc50f30274577b492 (diff) | |
download | jquery-ui-30ad5339489749be823757055aefa8311bd598d6.tar.gz jquery-ui-30ad5339489749be823757055aefa8311bd598d6.zip |
updated the condition to assert that values.legnth ==2 and range: true. (fixed #3736 - Slider: some handles get stuck when using two or more handles)
Diffstat (limited to 'ui/ui.slider.js')
-rw-r--r-- | ui/ui.slider.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ui/ui.slider.js b/ui/ui.slider.js index 2f5ac1e7b..e011043ea 100644 --- a/ui/ui.slider.js +++ b/ui/ui.slider.js @@ -336,8 +336,10 @@ $.widget("ui.slider", $.extend({}, $.ui.mouse, { var otherVal = this.values(index ? 0 : 1); - if ((index == 0 && newVal >= otherVal) || (index == 1 && newVal <= otherVal)) - newVal = otherVal; + if ((this.options.values.length == 2 && this.options.range === true) && + ((index == 0 && newVal > otherVal) || (index == 1 && newVal < otherVal))){ + newVal = otherVal; + } if (newVal != this.values(index)) { var newValues = this.values(); |