Skip to content
Permalink
Browse files

Fixed #4315 (Slider: clicking on slider with negative values causes e…

…rror 'closestHandle is undefined')
  • Loading branch information...
rdworth committed Mar 10, 2009
1 parent 4bfadc4 commit 7e3b8483a351d29d64029eda8e814c07053296f0
Showing with 1 addition and 1 deletion.
  1. +1 −1 ui/ui.slider.js
@@ -193,7 +193,7 @@ $.widget("ui.slider", $.extend({}, $.ui.mouse, {
var position = { x: event.pageX, y: event.pageY };
var normValue = this._normValueFromMouse(position);

var distance = this._valueMax() + 1, closestHandle;
var distance = this._valueMax() - this._valueMin() + 1, closestHandle;
var self = this, index;
this.handles.each(function(i) {
var thisDistance = Math.abs(normValue - self.values(i));

0 comments on commit 7e3b848

Please sign in to comment.
You can’t perform that action at this time.