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

Miklos Vajna (via logerrit) logerrit at kemper.freedesktop.org
Wed Oct 30 10:30:47 UTC 2019


 loleaflet/src/layer/tile/CalcTileLayer.js    |    2 +-
 loleaflet/src/layer/tile/ImpressTileLayer.js |    2 +-
 loleaflet/src/layer/tile/WriterTileLayer.js  |    4 ++--
 3 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 91d3f5da2648981570f3bcf897ac39065292e50d
Author:     Miklos Vajna <vmiklos at collabora.com>
AuthorDate: Wed Oct 30 09:31:20 2019 +0100
Commit:     Miklos Vajna <vmiklos at collabora.com>
CommitDate: Wed Oct 30 11:30:30 2019 +0100

    loleaflet: isTablet -> isTablet()
    
    The other references called this function object, so probably the rest
    of the cases just forgot to call the function, resulting in an
    always-true boolean expression.
    
    Change-Id: I409f3ef5a927cd5d5c6aaf8e354045f5ca8c427e
    Reviewed-on: https://gerrit.libreoffice.org/81732
    Reviewed-by: Szymon Kłos <szymon.klos at collabora.com>
    Reviewed-by: Miklos Vajna <vmiklos at collabora.com>
    Tested-by: Miklos Vajna <vmiklos at collabora.com>

diff --git a/loleaflet/src/layer/tile/CalcTileLayer.js b/loleaflet/src/layer/tile/CalcTileLayer.js
index 1b5ae48a8..1329183f5 100644
--- a/loleaflet/src/layer/tile/CalcTileLayer.js
+++ b/loleaflet/src/layer/tile/CalcTileLayer.js
@@ -14,7 +14,7 @@ L.CalcTileLayer = L.TileLayer.extend({
 	},
 
 	newAnnotation: function (comment) {
-		if (window.mode.isMobile() || window.mode.isTablet) {
+		if (window.mode.isMobile() || window.mode.isTablet()) {
 			var that = this;
 			this.newAnnotationVex(comment, function(annotation) { that._onAnnotationSave(annotation); });
 		} else {
diff --git a/loleaflet/src/layer/tile/ImpressTileLayer.js b/loleaflet/src/layer/tile/ImpressTileLayer.js
index 2ad1ffed1..ba2a2e87b 100644
--- a/loleaflet/src/layer/tile/ImpressTileLayer.js
+++ b/loleaflet/src/layer/tile/ImpressTileLayer.js
@@ -297,7 +297,7 @@ L.ImpressTileLayer = L.TileLayer.extend({
 	onAnnotationModify: function (annotation) {
 		this.onAnnotationCancel();
 		this._selectedAnnotation = annotation._data.id;
-		if (window.mode.isMobile() || window.mode.isTablet) {
+		if (window.mode.isMobile() || window.mode.isTablet()) {
 			this.newAnnotationVex(annotation, this.onAnnotationSave, /* isMod */ true);
 		} else {
 			annotation.edit();
diff --git a/loleaflet/src/layer/tile/WriterTileLayer.js b/loleaflet/src/layer/tile/WriterTileLayer.js
index 368cd89e4..5758ce9fc 100644
--- a/loleaflet/src/layer/tile/WriterTileLayer.js
+++ b/loleaflet/src/layer/tile/WriterTileLayer.js
@@ -21,7 +21,7 @@ L.WriterTileLayer = L.TileLayer.extend({
 		if (comment.anchorPos) {
 			this._annotations.modify(this._annotations.add(comment));
 		}
-		if (window.mode.isMobile() || window.mode.isTablet) {
+		if (window.mode.isMobile() || window.mode.isTablet()) {
 			var that = this;
 			this.newAnnotationVex(comment, function(annotation) { that._annotations._onAnnotationSave(annotation); });
 		}
@@ -208,7 +208,7 @@ L.WriterTileLayer = L.TileLayer.extend({
 	},
 
 	onAnnotationModify: function (annotation) {
-		if (window.mode.isMobile() || window.mode.isTablet) {
+		if (window.mode.isMobile() || window.mode.isTablet()) {
 			var that = this;
 			this.newAnnotationVex(annotation, function(annotation) { that._annotations._onAnnotationSave(annotation); }, /* isMod */ true);
 		} else {


More information about the Libreoffice-commits mailing list