[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-4' - loleaflet/js loleaflet/src
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Fri Apr 5 10:16:48 UTC 2019
loleaflet/js/jquery.mCustomScrollbar.js | 3 +--
loleaflet/src/control/Control.Scroll.js | 6 +-----
loleaflet/src/layer/tile/TileLayer.js | 6 +-----
3 files changed, 3 insertions(+), 12 deletions(-)
New commits:
commit 4506d7c2de2c20c4211300ac58cecd2a42e7bb27
Author: Tor Lillqvist <tml at collabora.com>
AuthorDate: Thu Jan 24 12:55:00 2019 +0200
Commit: Tor Lillqvist <tml at collabora.com>
CommitDate: Fri Apr 5 12:16:29 2019 +0200
tdf#122359: Un-revert and edit in a attempt to reach a compromise
Change-Id: I0f23c70b3c4a07bae24e490eb8d1a5e56a4ba9ee
Reviewed-on: https://gerrit.libreoffice.org/70289
Reviewed-by: Tor Lillqvist <tml at collabora.com>
Tested-by: Tor Lillqvist <tml at collabora.com>
diff --git a/loleaflet/js/jquery.mCustomScrollbar.js b/loleaflet/js/jquery.mCustomScrollbar.js
index 442b20504..e242263e2 100644
--- a/loleaflet/js/jquery.mCustomScrollbar.js
+++ b/loleaflet/js/jquery.mCustomScrollbar.js
@@ -2127,8 +2127,7 @@ and dependencies (minified).
// hidden part of the document (for instance when pressing enter on the
// last visible line). The options.timeout==1 is a silly way to detect
// the mouse-wheel scrolling.
- if((window.ThisIsAMobileApp && (options.drag || options.timeout===1 || options.calledFromInvalidateCursorMsg==true)) ||
- (!window.ThisIsAMobileApp)) {
+ if(!window.ThisIsAMobileApp || options.drag || options.timeout===1 || options.calledFromInvalidateCursorMsg==true){
/* callbacks: whileScrolling */
if(_cb("whileScrolling")){_mcs(); o.callbacks.whileScrolling.call(el[0]);}
}
diff --git a/loleaflet/src/control/Control.Scroll.js b/loleaflet/src/control/Control.Scroll.js
index e8df36eb8..829ce18ab 100644
--- a/loleaflet/src/control/Control.Scroll.js
+++ b/loleaflet/src/control/Control.Scroll.js
@@ -155,11 +155,7 @@ L.Control.Scroll = L.Control.extend({
_onScrollTo: function (e) {
// triggered by the document (e.g. search result out of the viewing area)
- if (window.ThisIsAMobileApp) {
- $('.scroll-container').mCustomScrollbar('scrollTo', [e.y, e.x], {calledFromInvalidateCursorMsg: e.calledFromInvalidateCursorMsg});
- } else {
- $('.scroll-container').mCustomScrollbar('scrollTo', [e.y, e.x]);
- }
+ $('.scroll-container').mCustomScrollbar('scrollTo', [e.y, e.x], {calledFromInvalidateCursorMsg: e.calledFromInvalidateCursorMsg});
},
_onScrollBy: function (e) {
diff --git a/loleaflet/src/layer/tile/TileLayer.js b/loleaflet/src/layer/tile/TileLayer.js
index f39102829..42c880e57 100644
--- a/loleaflet/src/layer/tile/TileLayer.js
+++ b/loleaflet/src/layer/tile/TileLayer.js
@@ -1634,11 +1634,7 @@ L.TileLayer = L.GridLayer.extend({
if (!zoom && !(this._selectionHandles.start && this._selectionHandles.start.isDragged) &&
!(this._selectionHandles.end && this._selectionHandles.end.isDragged) &&
!(docLayer._followEditor || docLayer._followUser)) {
- if (window.ThisIsAMobileApp) {
- this._map.fire('scrollto', {x: center.x, y: center.y, calledFromInvalidateCursorMsg: scroll !== undefined});
- } else {
- this._map.fire('scrollto', {x: center.x, y: center.y});
- }
+ this._map.fire('scrollto', {x: center.x, y: center.y, calledFromInvalidateCursorMsg: scroll !== undefined});
}
}
More information about the Libreoffice-commits
mailing list