From 8bdffe248ad99c1c8cd840cb091926cb06e44880 Mon Sep 17 00:00:00 2001 From: Dzwiedzminator <31314073+Dzwiedzminator@users.noreply.github.com> Date: Thu, 24 Aug 2017 15:40:17 +0200 Subject: [PATCH 1/2] Update VideoOverlay.js wrong keyword uses - className should be used instead found this when testing new leaflet on ie8 - map doesn't load because of this --- src/layer/VideoOverlay.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/layer/VideoOverlay.js b/src/layer/VideoOverlay.js index 2c7d6d9422e..319ff30c74f 100644 --- a/src/layer/VideoOverlay.js +++ b/src/layer/VideoOverlay.js @@ -39,8 +39,8 @@ export var VideoOverlay = ImageOverlay.extend({ var wasElementSupplied = this._url.tagName === 'VIDEO'; var vid = this._image = wasElementSupplied ? this._url : DomUtil.create('video'); - vid.class = vid.class || ''; - vid.class += 'leaflet-image-layer ' + (this._zoomAnimated ? 'leaflet-zoom-animated' : ''); + vid.className = vid.className || ''; + vid.className += 'leaflet-image-layer ' + (this._zoomAnimated ? 'leaflet-zoom-animated' : ''); vid.onselectstart = Util.falseFn; vid.onmousemove = Util.falseFn; From f7faad2993414a0c09024879b7f17da1f5f4a365 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20S=C3=A1nchez=20Ortega?= Date: Fri, 25 Aug 2017 09:11:17 +0200 Subject: [PATCH 2/2] Use DomUtil.addClass instead of modifying el.className --- src/layer/VideoOverlay.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/layer/VideoOverlay.js b/src/layer/VideoOverlay.js index 319ff30c74f..8e8bc5b9e2c 100644 --- a/src/layer/VideoOverlay.js +++ b/src/layer/VideoOverlay.js @@ -39,8 +39,8 @@ export var VideoOverlay = ImageOverlay.extend({ var wasElementSupplied = this._url.tagName === 'VIDEO'; var vid = this._image = wasElementSupplied ? this._url : DomUtil.create('video'); - vid.className = vid.className || ''; - vid.className += 'leaflet-image-layer ' + (this._zoomAnimated ? 'leaflet-zoom-animated' : ''); + DomUtil.addClass('leaflet-image-layer'); + if (this._zoomAnimated) { DomUtil.addClass('leaflet-zoom-animated'); } vid.onselectstart = Util.falseFn; vid.onmousemove = Util.falseFn;