Merge pull request #1458 from Intermedix/bug-insert-valueExtent
Fix bug in ol.structs.RBush#update
This commit is contained in:
@@ -555,7 +555,6 @@ ol.structs.RBush.prototype.insert = function(extent, value) {
|
||||
var key = this.getKey_(value);
|
||||
goog.asserts.assert(!this.valueExtent_.hasOwnProperty(key));
|
||||
this.insert_(extent, value, this.root_.height - 1);
|
||||
this.valueExtent_[key] = ol.extent.clone(extent);
|
||||
};
|
||||
|
||||
|
||||
@@ -583,6 +582,8 @@ ol.structs.RBush.prototype.insert_ = function(extent, value, level) {
|
||||
for (; i >= 0; --i) {
|
||||
ol.extent.extend(path[i].extent, extent);
|
||||
}
|
||||
var key = this.getKey_(value);
|
||||
this.valueExtent_[key] = ol.extent.clone(extent);
|
||||
return node;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user