File tree 1 file changed +9
-6
lines changed
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) {
83
83
var y = this . yData = this . pickYData = options . y ;
84
84
85
85
var xy = options . xy ;
86
- var userBounds = options . bounds ;
86
+ var userBounds = options . xbounds && options . ybounds
87
87
var index = options . indices ;
88
88
89
- var len = x . length ,
89
+ var len ,
90
90
idToIndex ,
91
91
positions ,
92
92
bounds = this . bounds ;
@@ -96,13 +96,14 @@ proto.updateFast = function(options) {
96
96
if ( xy ) {
97
97
98
98
positions = xy ;
99
+ len = xy . length >>> 1 ;
99
100
100
101
if ( userBounds ) {
101
102
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 ] ;
106
107
107
108
} else {
108
109
@@ -137,6 +138,8 @@ proto.updateFast = function(options) {
137
138
138
139
} else {
139
140
141
+ len = x . length ;
142
+
140
143
positions = new Float32Array ( 2 * len ) ;
141
144
idToIndex = new Int32Array ( len ) ;
142
145
You can’t perform that action at this time.
0 commit comments