[Libreoffice-commits] online.git: loleaflet/src

Jan Holesovsky kendy at collabora.com
Mon Jan 11 07:44:34 PST 2016


 loleaflet/src/map/Map.js |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit aca8d673b2378e1a224e417fc84ca00058a56642
Author: Jan Holesovsky <kendy at collabora.com>
Date:   Mon Jan 11 16:41:30 2016 +0100

    loleaflet: Don't crash on map.remove() when the underlying DOM is gone.

diff --git a/loleaflet/src/map/Map.js b/loleaflet/src/map/Map.js
index 6692485..f7c93c8 100644
--- a/loleaflet/src/map/Map.js
+++ b/loleaflet/src/map/Map.js
@@ -601,7 +601,7 @@ L.Map = L.Evented.extend({
 			'mouseover mouseout mousemove contextmenu keydown keypress keyup trplclick qdrplclick', this._handleDOMEvent, this);
 		L.DomEvent[onOff](this._textArea, 'copy paste keydown keypress keyup', this._handleDOMEvent, this);
 
-		if (this.options.trackResize) {
+		if (this.options.trackResize && this._resizeDetector.contentWindow) {
 			L.DomEvent[onOff](this._resizeDetector.contentWindow, 'resize', this._onResize, this);
 		}
 	},


More information about the Libreoffice-commits mailing list