From 8b860d420556cfdc4d2aa1b9afcdf6b213d7a623 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Francisco=20L=C3=B3pez?= Date: Tue, 21 Mar 2017 17:33:21 +0100 Subject: [PATCH] Back to layer and add zIndex to the container --- lib/torque/leaflet/canvas_layer.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/torque/leaflet/canvas_layer.js b/lib/torque/leaflet/canvas_layer.js index fb6010e..f6aefc5 100644 --- a/lib/torque/leaflet/canvas_layer.js +++ b/lib/torque/leaflet/canvas_layer.js @@ -4,7 +4,7 @@ require('./leaflet_tileloader_mixin'); * full canvas layer implementation for Leaflet */ -L.CanvasLayer = L.GridLayer.extend({ +L.CanvasLayer = L.Layer.extend({ includes: [L.Mixin.Events, L.Mixin.TileLoader], @@ -186,6 +186,7 @@ L.CanvasLayer = L.GridLayer.extend({ }, setZIndex: function(zIndex) { + this._container.style.zIndex = zIndex; this._canvas.style.zIndex = zIndex; if (this.options.zoomAnimation) { this._backCanvas.style.zIndex = zIndex;