projects
/
dygraphs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge pull request #171 from kberg/master
[dygraphs.git]
/
dygraph.js
diff --git
a/dygraph.js
b/dygraph.js
index
621ea32
..
9d58201
100644
(file)
--- a/
dygraph.js
+++ b/
dygraph.js
@@
-1670,7
+1670,7
@@
Dygraph.prototype.findClosestPoint = function(domX, domY) {
var minDist = Infinity;
var idx = -1;
var dist, dx, dy, point, closestPoint, closestSeries;
var minDist = Infinity;
var idx = -1;
var dist, dx, dy, point, closestPoint, closestSeries;
- for (
var setIdx = 0; setIdx < this.layout_.datasets.length; ++setIdx
) {
+ for (
var setIdx = this.layout_.datasets.length - 1 ; setIdx >= 0 ; --setIdx
) {
var points = this.layout_.points[setIdx];
for (var i = 0; i < points.length; ++i) {
var point = points[i];
var points = this.layout_.points[setIdx];
for (var i = 0; i < points.length; ++i) {
var point = points[i];