X-Git-Url: https://adrianiainlam.tk/git/?a=blobdiff_plain;f=dygraph.js;h=3502c312742873cd87e734e8da788b0db1fd4eca;hb=eb96f83382a3b80db03db8b5fd06f02e65cedf7d;hp=99795874e77b2ffc846d86fbcc97fde7acbe5e1c;hpb=afdb20d88ecfd0d3464adf2ca7a8f87d7935409b;p=dygraphs.git diff --git a/dygraph.js b/dygraph.js index 9979587..3502c31 100644 --- a/dygraph.js +++ b/dygraph.js @@ -1021,7 +1021,11 @@ Dygraph.prototype.createStatusMessage_ = function() { div.className = "dygraph-legend"; for (var name in messagestyle) { if (messagestyle.hasOwnProperty(name)) { - div.style[name] = messagestyle[name]; + try { + div.style[name] = messagestyle[name]; + } catch (e) { + this.warn("You are using unsupported css properties for your browser in labelsDivStyles"); + } } } this.graphDiv.appendChild(div); @@ -1936,11 +1940,15 @@ Dygraph.prototype.updateSelection_ = function(opt_animFraction) { var circleSize = this.attr_('highlightCircleSize', pt.name); var callback = this.attr_("drawHighlightPointCallback", pt.name); + var color = this.plotter_.colors[pt.name]; if (!callback) { callback = Dygraph.Circles.DEFAULT; } + ctx.lineWidth = this.attr_('strokeWidth', pt.name); + ctx.strokeStyle = color; + ctx.fillStyle = color; callback(this.g, pt.name, ctx, canvasx, pt.canvasy, - this.plotter_.colors[pt.name], circleSize); + color, circleSize); } ctx.restore();