From: Nikhil Kasinadhuni Date: Thu, 11 Mar 2010 01:14:40 +0000 (-0800) Subject: Merge branch 'master' of git://github.com/danvk/dygraphs X-Git-Tag: v1.0.0~702^2~4 X-Git-Url: https://adrianiainlam.tk/git/?a=commitdiff_plain;h=8d34158cad7690d8ba23c863eafe804ff66d94dd;p=dygraphs.git Merge branch 'master' of git://github.com/danvk/dygraphs Conflicts: dygraph.js --- 8d34158cad7690d8ba23c863eafe804ff66d94dd diff --cc dygraph.js index 4fbf443,defac69..1b4600e --- a/dygraph.js +++ b/dygraph.js @@@ -902,10 -902,11 +902,11 @@@ Dygraph.prototype.mouseMove_ = function this.selPoints_ = []; var cumulative_sum = 0; // used only if we have a stackedGraph. var l = points.length; + var isStacked = this.attr_("stackedGraph"); - for (var i = 0; i < l; i++) { + for (var i = l - 1; i >= 0; i--) { if (points[i].xval == lastx) { - if (!this.attr_("stackedGraph")) { + if (!isStacked) { - this.selPoints_.push(points[i]); + this.selPoints_.unshift(points[i]); } else { // Clone the point, since we need to 'unstack' it below. Stacked points // are in reverse order.