Skip to content

Commit

Permalink
Fix highlight and unhighlight inconsistency.
Browse files Browse the repository at this point in the history
The unhighlight method retrieved the point differently from highlight,
and incorrectly.  It now matches the behavior of highlight.
  • Loading branch information
dnschnur committed Mar 12, 2013
1 parent aeddf4e commit eee071c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions jquery.flot.js
Expand Up @@ -2844,8 +2844,10 @@ Licensed under the MIT license.
if (typeof s == "number")
s = series[s];

if (typeof point == "number")
point = s.data[point];
if (typeof point == "number") {
var ps = s.datapoints.pointsize;
point = s.datapoints.points.slice(ps * point, ps * (point + 1));
}

var i = indexOfHighlight(s, point);
if (i != -1) {
Expand Down

1 comment on commit eee071c

@dnschnur
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resolves #987.

Please sign in to comment.