Skip to content

Commit

Permalink
fixed highchart.ValueAtX(..) exception
Browse files Browse the repository at this point in the history
  • Loading branch information
Meragon committed Oct 24, 2018
1 parent 70e3383 commit fd1ab3e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Controls/Highcharts/Highchart.cs
Original file line number Diff line number Diff line change
Expand Up @@ -729,7 +729,7 @@ private double ValueAtX(Series s, int x)

var xCoef = (float)(x - cachedPlotLeft) / cachedPlotWidth;
var dataIndex = (int)(xCoef * sdataCount);
if (dataIndex > sdataCount)
if (dataIndex >= sdataCount || dataIndex < 0)
return 0;

return s.data[dataIndex];
Expand Down
Binary file modified Controls/Highcharts/gradientFill.mat
Binary file not shown.

0 comments on commit fd1ab3e

Please sign in to comment.