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

Pranam Lashkari (via logerrit) logerrit at kemper.freedesktop.org
Mon Sep 21 16:15:41 UTC 2020


 loleaflet/src/layer/marker/Annotation.js |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 31c931658d5f7ed453a05085c3286f70fe769e46
Author:     Pranam Lashkari <lpranam at collabora.com>
AuthorDate: Mon Sep 21 19:25:54 2020 +0530
Commit:     Pranam Lashkari <lpranam at collabora.com>
CommitDate: Mon Sep 21 18:15:21 2020 +0200

    leaflet: show annotation marker only from the selected slide
    
    Change-Id: I6a9950f8f5be0f6e7393faf4f8718b94ffb05ebc
    Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103114
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
    Reviewed-by: Pranam Lashkari <lpranam at collabora.com>

diff --git a/loleaflet/src/layer/marker/Annotation.js b/loleaflet/src/layer/marker/Annotation.js
index dc4f94633..6a8701dc7 100644
--- a/loleaflet/src/layer/marker/Annotation.js
+++ b/loleaflet/src/layer/marker/Annotation.js
@@ -485,7 +485,8 @@ L.Annotation = L.Layer.extend({
 				}),
 				draggable: true
 			});
-			this._map.addLayer(this._annotationMarker);
+			if (this._map._docLayer._partHashes[this._map._docLayer._selectedPart] == this._data.parthash)
+				this._map.addLayer(this._annotationMarker);
 		}
 		if (this._data.rectangle != null) {
 			var stringTwips = this._data.rectangle.match(/\d+/g);


More information about the Libreoffice-commits mailing list