r2227 - trunk/ui

r2227 - trunk/ui


Author: rdworth
Date: Mon Mar 9 18:35:09 2009
New Revision: 2227
Modified:
trunk/ui/ui.slider.js
Log:
Fixed #4292 (Slider: ui.value incorrect in slide event if handle at value 0)
Modified: trunk/ui/ui.slider.js
==============================================================================
--- trunk/ui/ui.slider.js    (original)
+++ trunk/ui/ui.slider.js    Mon Mar 9 18:35:09 2009
@@ -299,11 +299,15 @@
    },
    _start: function(event, index) {
-        this._trigger("start", event, {
+        var uiHash = {
            handle: this.handles[index],
-            value: this.value(),
-            values: this.values()
-        });
+            value: this.value()
+        };
+        if (this.options.values && this.options.values.length) {
+            uiHash.value = this.values(index)
+            uiHash.values = this.values()
+        }
+        this._trigger("start", event, uiHash);
    },
    _slide: function(event, index, newVal) {