loleaflet/src/map/Map.js | 4 ++++ 1 file changed, 4 insertions(+) New commits: commit 46a314206b720858127e254d2ae499e12fa53b60 Author: Henry Castro <hcas...@collabora.com> Date: Thu Sep 8 16:48:56 2016 -0400
loleaflet: avoid undefined variables when map not loaded diff --git a/loleaflet/src/map/Map.js b/loleaflet/src/map/Map.js index 1d01ff7..e2204b4 100644 --- a/loleaflet/src/map/Map.js +++ b/loleaflet/src/map/Map.js @@ -790,6 +790,8 @@ L.Map = L.Evented.extend({ }, _onLostFocus: function () { + if (!this._loaded) { return; } + var doclayer = this._docLayer; if (doclayer._isCursorVisible && doclayer._isCursorOverlayVisible) { doclayer._visibleCursorOnLostFocus = doclayer._visibleCursor; @@ -802,6 +804,8 @@ L.Map = L.Evented.extend({ }, _onGotFocus: function () { + if (!this._loaded) { return; } + var doclayer = this._docLayer; if (doclayer._isCursorVisibleOnLostFocus && doclayer._isCursorOverlayVisibleOnLostFocus) { // we restore the old cursor position by a small delay, so that if the user clicks _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits