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

Marco Cecchetti marco.cecchetti at collabora.com
Tue May 16 11:21:39 UTC 2017


 loleaflet/src/control/Parts.js            |    3 ---
 loleaflet/src/layer/marker/DivOverlay.js  |    2 +-
 loleaflet/src/layer/tile/CalcTileLayer.js |    3 +++
 3 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit ef5376197e2893c68cc381ecf997dd2b8d7dbf82
Author: Marco Cecchetti <marco.cecchetti at collabora.com>
Date:   Tue May 2 10:51:16 2017 +0200

    Loleaflet: Fix for row/col headers and annotation marks on tab switching
    
    Change-Id: Id0f52603af7eaa49979f68d222c9c94e79cf65b1
    Reviewed-on: https://gerrit.libreoffice.org/37251
    Reviewed-by: Jan Holesovsky <kendy at collabora.com>
    Tested-by: Jan Holesovsky <kendy at collabora.com>

diff --git a/loleaflet/src/control/Parts.js b/loleaflet/src/control/Parts.js
index 84e92f31..1071db03 100644
--- a/loleaflet/src/control/Parts.js
+++ b/loleaflet/src/control/Parts.js
@@ -51,9 +51,6 @@ L.Map.include({
 		if (!this._searchRequested) {
 			this.focus();
 		}
-		if (docLayer._docType === 'spreadsheet') {
-			this.fire('updaterowcolumnheaders', {x: this._getTopLeftPoint().x, y: this._getTopLeftPoint(), offset: {x: undefined, y: undefined}});
-		}
 	},
 
 	getPreview: function (id, index, maxWidth, maxHeight, options) {
diff --git a/loleaflet/src/layer/marker/DivOverlay.js b/loleaflet/src/layer/marker/DivOverlay.js
index a562d728..9ab6d4f8 100644
--- a/loleaflet/src/layer/marker/DivOverlay.js
+++ b/loleaflet/src/layer/marker/DivOverlay.js
@@ -28,7 +28,7 @@ L.DivOverlay = L.Layer.extend({
 	},
 
 	update: function () {
-		if (this._container) {
+		if (this._container && this._map) {
 			var topLeft = this._map.latLngToLayerPoint(this._latLngBounds.getNorthWest());
 			var size = this._map.latLngToLayerPoint(this._latLngBounds.getSouthEast()).subtract(topLeft);
 			L.DomUtil.setPosition(this._container, topLeft);
diff --git a/loleaflet/src/layer/tile/CalcTileLayer.js b/loleaflet/src/layer/tile/CalcTileLayer.js
index cb82396d..f0a39644 100644
--- a/loleaflet/src/layer/tile/CalcTileLayer.js
+++ b/loleaflet/src/layer/tile/CalcTileLayer.js
@@ -210,6 +210,9 @@ L.CalcTileLayer = L.TileLayer.extend({
 		} else if (textMsg.startsWith('invalidateheader: row')) {
 			this._map.fire('updaterowcolumnheaders', {x: 0, y: this._map._getTopLeftPoint().y, offset: {x: 0, y: undefined}});
 			this._map._socket.sendMessage('commandvalues command=.uno:ViewAnnotationsPosition');
+		} else if (textMsg.startsWith('invalidateheader: all')) {
+			this._map.fire('updaterowcolumnheaders', {x: this._map._getTopLeftPoint().x, y: this._map._getTopLeftPoint(), offset: {x: undefined, y: undefined}});
+			this._map._socket.sendMessage('commandvalues command=.uno:ViewAnnotationsPosition');
 		} else {
 			L.TileLayer.prototype._onMessage.call(this, textMsg, img);
 		}


More information about the Libreoffice-commits mailing list