From: Dan Vanderkam Date: Mon, 14 Dec 2009 08:55:58 +0000 (-0800) Subject: actually draw the graph X-Git-Tag: v1.0.0~789 X-Git-Url: https://adrianiainlam.tk/git/?a=commitdiff_plain;h=964f30c6acd7b20818da824da434f18efaf63575;p=dygraphs.git actually draw the graph --- diff --git a/dygraph.js b/dygraph.js index a7c7059..8c3bc59 100644 --- a/dygraph.js +++ b/dygraph.js @@ -1746,6 +1746,10 @@ Dygraph.prototype.updateOptions = function(attrs) { * Resizes the dygraph. If no parameters are specified, resizes to fill the * containing div (which has presumably changed size since the dygraph was * instantiated. If the width/height are specified, the div will be resized. + * + * This is far more efficient than destroying and re-instantiating a + * Dygraph, since it doesn't have to reparse the underlying data. + * * @param {Number} width Width (in pixels) * @param {Number} height Height (in pixels) */ @@ -1768,6 +1772,7 @@ Dygraph.prototype.resize = function(width, height) { } this.createInterface_(); + this.drawGraph_(this.rawData_); }; /**