File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -83,10 +83,10 @@ proto.updateFast = function(options) {
8383 var y = this . yData = this . pickYData = options . y ;
8484
8585 var xy = options . xy ;
86- var userBounds = options . bounds ;
86+ var userBounds = options . xbounds && options . ybounds
8787 var index = options . indices ;
8888
89- var len = x . length ,
89+ var len ,
9090 idToIndex ,
9191 positions ,
9292 bounds = this . bounds ;
@@ -96,13 +96,14 @@ proto.updateFast = function(options) {
9696 if ( xy ) {
9797
9898 positions = xy ;
99+ len = xy . length >>> 1 ;
99100
100101 if ( userBounds ) {
101102
102- bounds [ 0 ] = userBounds [ 0 ] ;
103- bounds [ 1 ] = userBounds [ 1 ] ;
104- bounds [ 2 ] = userBounds [ 2 ] ;
105- bounds [ 3 ] = userBounds [ 3 ] ;
103+ bounds [ 0 ] = options . xbounds [ 0 ] ;
104+ bounds [ 2 ] = options . xbounds [ 1 ] ;
105+ bounds [ 1 ] = options . ybounds [ 0 ] ;
106+ bounds [ 3 ] = options . ybounds [ 1 ] ;
106107
107108 } else {
108109
@@ -137,6 +138,8 @@ proto.updateFast = function(options) {
137138
138139 } else {
139140
141+ len = x . length ;
142+
140143 positions = new Float32Array ( 2 * len ) ;
141144 idToIndex = new Int32Array ( len ) ;
142145
You can’t perform that action at this time.
0 commit comments