[Libreoffice-commits] online.git: loleaflet/src
Henry Castro
hcastro at collabora.com
Mon Apr 24 13:46:13 UTC 2017
loleaflet/src/layer/marker/Annotation.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit a33e9eab7682f5b7e2f4c47a83de416306c96dc9
Author: Henry Castro <hcastro at collabora.com>
Date: Mon Apr 24 09:45:00 2017 -0400
loleaflet: disable the annotation menu if the document is read only
Change-Id: Ic5973e582e56d2452672219bdd443ec8dd551dab
diff --git a/loleaflet/src/layer/marker/Annotation.js b/loleaflet/src/layer/marker/Annotation.js
index 8a4c7001..7a9ae2a9 100644
--- a/loleaflet/src/layer/marker/Annotation.js
+++ b/loleaflet/src/layer/marker/Annotation.js
@@ -172,7 +172,7 @@ L.Annotation = L.Layer.extend({
}, this);
}
- if (this.options.noMenu !== true) {
+ if (this.options.noMenu !== true && this._map._permission !== 'readonly') {
var tdMenu = L.DomUtil.create(tagTd, 'loleaflet-annotation-menubar', tr);
var divMenu = L.DomUtil.create(tagDiv, this._data.trackchange ? 'loleaflet-annotation-menu-redline' : 'loleaflet-annotation-menu', tdMenu);
divMenu.title = _('Open menu');
More information about the Libreoffice-commits
mailing list