sets cartocss once tiles have been loaded
This commit is contained in:
parent
0e9184e026
commit
2377029350
@ -80,8 +80,10 @@ L.TorqueLayer = L.CanvasLayer.extend({
|
||||
if (this.options.tileJSON) this.options.provider = 'tileJSON';
|
||||
|
||||
this.provider = new this.providers[this.options.provider](options);
|
||||
options.layer = this;
|
||||
this.renderer = new this.renderers[this.options.renderer](this.getCanvas(), options);
|
||||
|
||||
|
||||
options.ready = function() {
|
||||
self.fire("change:bounds", {
|
||||
bounds: self.provider.getBounds()
|
||||
@ -94,6 +96,10 @@ L.TorqueLayer = L.CanvasLayer.extend({
|
||||
self.setKeys(self.getKeys());
|
||||
};
|
||||
|
||||
this.on('tilesLoaded', function () {
|
||||
self.renderer.setCartoCSS(self.renderer.style);
|
||||
})
|
||||
|
||||
this.renderer.on("allIconsLoaded", this.render.bind(this));
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user