[Libreoffice-commits] online.git: loleaflet/src
Henry Castro
hcastro at collabora.com
Fri Nov 10 19:09:05 UTC 2017
loleaflet/src/layer/AnnotationManager.js | 2 ++
1 file changed, 2 insertions(+)
New commits:
commit bbb82ebd29f677087fd945579c943429bf545ad7
Author: Henry Castro <hcastro at collabora.com>
Date: Fri Nov 10 15:04:38 2017 -0400
loleafet: prevent default context menu on comments
and tracked changes
Change-Id: Iafd0f3128553f87e9c2fdf5440b039c8d710b2e6
diff --git a/loleaflet/src/layer/AnnotationManager.js b/loleaflet/src/layer/AnnotationManager.js
index 31580bd5..09601615 100644
--- a/loleaflet/src/layer/AnnotationManager.js
+++ b/loleaflet/src/layer/AnnotationManager.js
@@ -63,6 +63,7 @@ L.AnnotationManager = L.Class.extend({
weight: 2,
opacity: 0.25
});
+ L.DomEvent.on(comment.textSelected, 'contextmenu', L.DomEvent.preventDefault);
comment.textSelected.on('click', function(e) {
// Simulate a click at this position in the document
var latlng = this._map.mouseEventToLatLng(e.originalEvent);
@@ -100,6 +101,7 @@ L.AnnotationManager = L.Class.extend({
fillOpacity: 0,
opacity: 0
});
+ L.DomEvent.on(redline.textSelected, 'contextmenu', L.DomEvent.preventDefault);
redline.textSelected.on('click', function(e) {
// Simulate a click at this position in the document
var latlng = this._map.mouseEventToLatLng(e.originalEvent);
More information about the Libreoffice-commits
mailing list