From: Dan Vanderkam Date: Thu, 3 Sep 2009 06:50:05 +0000 (+0000) Subject: fix shallow copy bug, regen combined X-Git-Tag: v1.0.0~887 X-Git-Url: https://adrianiainlam.tk/git/?a=commitdiff_plain;h=b8339f6ebc65b1649078667fa06f43424a2a5b7b;p=dygraphs.git fix shallow copy bug, regen combined --- diff --git a/dygraph-combined.js b/dygraph-combined.js index 61802b7..2867e8c 100644 --- a/dygraph-combined.js +++ b/dygraph-combined.js @@ -4783,7 +4783,7 @@ DateGraph.DEFAULT_WIDTH=480; DateGraph.DEFAULT_HEIGHT=320; DateGraph.DEFAULT_STROKE_WIDTH=1; DateGraph.AXIS_LINE_WIDTH=0.3; -DateGraph.DEFAULT_ATTRS={pixelsPerXLabel:60,labelsDivWidth:250,labelsDivStyles:{}}; +DateGraph.DEFAULT_ATTRS={highlightCircleSize:3,pixelsPerXLabel:60,labelsDivWidth:250,labelsDivStyles:{}}; DateGraph.prototype.__init__=function(div,_52,_53,_54){ this.maindiv_=div; this.labels_=_53; @@ -4807,7 +4807,8 @@ this.xTicker_=_54.xTicker||DateGraph.prototype.dateTicker; this.sigma_=_54.sigma||2; this.wilsonInterval_=_54.wilsonInterval||true; this.customBars_=_54.customBars||false; -this.attrs_=DateGraph.DEFAULT_ATTRS; +this.attrs_={}; +MochiKit.Base.update(this.attrs_,DateGraph.DEFAULT_ATTRS); MochiKit.Base.update(this.attrs_,_54); if(typeof this.attrs_.pixelsPerXLabel=="undefined"){ this.attrs_.pixelsPerXLabel=60; @@ -5036,7 +5037,7 @@ if(_105[i].xval==_106){ _111.push(_105[i]); } } -var _112=3; +var _112=this.attrs_.highlightCircleSize; var ctx=this.canvas_.getContext("2d"); if(this.previousVerticalX_>=0){ var px=this.previousVerticalX_; diff --git a/dygraph.js b/dygraph.js index 4f5eca5..c0a67cb 100644 --- a/dygraph.js +++ b/dygraph.js @@ -121,7 +121,8 @@ DateGraph.prototype.__init__ = function(div, file, labels, attrs) { this.wilsonInterval_ = attrs.wilsonInterval || true; this.customBars_ = attrs.customBars || false; - this.attrs_ = DateGraph.DEFAULT_ATTRS; + this.attrs_ = {}; + MochiKit.Base.update(this.attrs_, DateGraph.DEFAULT_ATTRS); MochiKit.Base.update(this.attrs_, attrs); if (typeof this.attrs_.pixelsPerXLabel == 'undefined') {