X-Git-Url: https://adrianiainlam.tk/git/?a=blobdiff_plain;f=plugins%2Faxes.js;h=1f9c256ca2d6c94ac5835644c78b2b69fe9df646;hb=5baf7a08e52ae0c668c9578bdeb2d63b68f829fc;hp=940fcecff66aee9c8016297bcafb32407e9a661f;hpb=beeabac2f71ae45c510b0355d0e76972083a6ca6;p=dygraphs.git diff --git a/plugins/axes.js b/plugins/axes.js index 940fcec..1f9c256 100644 --- a/plugins/axes.js +++ b/plugins/axes.js @@ -6,6 +6,8 @@ Dygraph.Plugins.Axes = (function() { +"use strict"; + /* Bits of jankiness: @@ -33,7 +35,7 @@ axes.prototype.activate = function(g) { return { layout: this.layout, clearChart: this.clearChart, - drawChart: this.drawChart + willDrawChart: this.willDrawChart }; }; @@ -82,9 +84,9 @@ axes.prototype.detachLabels = function() { axes.prototype.clearChart = function(e) { var g = e.dygraph; this.detachLabels(); -} +}; -axes.prototype.drawChart = function(e) { +axes.prototype.willDrawChart = function(e) { var g = e.dygraph; if (!g.getOption('drawXAxis') && !g.getOption('drawYAxis')) return; @@ -268,7 +270,7 @@ axes.prototype.drawChart = function(e) { } context.restore(); -} +}; return axes; })();