From: Dan Vanderkam Date: Tue, 13 Apr 2010 21:40:12 +0000 (-0700) Subject: add another underlay callback parameter, plus a nicer demo X-Git-Tag: v1.0.0~695^2~2 X-Git-Url: https://adrianiainlam.tk/git/?a=commitdiff_plain;h=d9e6fa471081631155f03455c9ff47626684bcd3;p=dygraphs.git add another underlay callback parameter, plus a nicer demo --- diff --git a/dygraph-canvas.js b/dygraph-canvas.js index 2c18345..b83e54a 100644 --- a/dygraph-canvas.js +++ b/dygraph-canvas.js @@ -279,7 +279,7 @@ DygraphCanvasRenderer.prototype.render = function() { var ctx = this.element.getContext("2d"); if (this.options.underlayCallback) { - this.options.underlayCallback(ctx, this.area, this.layout); + this.options.underlayCallback(ctx, this.area, this.layout, this.dygraph_); } if (this.options.drawYGrid) { diff --git a/tests/highlighted-region.html b/tests/highlighted-region.html new file mode 100644 index 0000000..48d803e --- /dev/null +++ b/tests/highlighted-region.html @@ -0,0 +1,55 @@ + + + Highlighted Region + + + + + + + + +

Should draw a time series with an unusual region highlighted:

+
+ +

When you zoom/pan, the region should remain highlighted.

+ + + +