loleaflet/src/map/anim/Map.ZoomAnimation.js | 2 +- loleaflet/src/map/handler/Map.TouchGesture.js | 10 ++++++++-- 2 files changed, 9 insertions(+), 3 deletions(-)
New commits: commit 6b3e0cc9f9940c07bf478a7bd240bb56be3810eb Author: Jan Holesovsky <ke...@collabora.com> AuthorDate: Thu Sep 3 22:22:05 2020 +0200 Commit: Jan Holesovsky <ke...@collabora.com> CommitDate: Thu Sep 3 22:30:28 2020 +0200 calc canvas: Set the zoom directly when swiping. The zoom itself does not honor the setting of the center yet, and the re-rendering while swiping does not happen much either. Change-Id: I03c99acb7e1f92aa33be03287676699aad2b37c1 diff --git a/loleaflet/src/map/handler/Map.TouchGesture.js b/loleaflet/src/map/handler/Map.TouchGesture.js index 895977228..fd81d9b37 100644 --- a/loleaflet/src/map/handler/Map.TouchGesture.js +++ b/loleaflet/src/map/handler/Map.TouchGesture.js @@ -549,7 +549,10 @@ L.Map.TouchGesture = L.Handler.extend({ L.Util.cancelAnimFrame(this._animRequest); this._animRequest = L.Util.requestAnimFrame(function () { - this._map._animateZoom(this._center, this._zoom, false, true); + if (typeof this._map._animateZoom === 'function') + this._map._animateZoom(this._center, this._zoom, false, true); + else + this._map._resetView(this._center, this._zoom, false, true); }, this, true, this._map._container); }, @@ -573,7 +576,10 @@ L.Map.TouchGesture = L.Handler.extend({ if (this._center) { L.Util.cancelAnimFrame(this._animRequest); - this._map._animateZoom(this._center, finalZoom, true, true); + if (typeof this._map._animateZoom === 'function') + this._map._animateZoom(this._center, finalZoom, true, true); + else + this._map._resetView(this._center, finalZoom, false, true); } if (this._map._docLayer && this._map._docLayer._annotations) { commit 08e36ef8e985e6cf4f32a0de53c8d86be96dc50b Author: Jan Holesovsky <ke...@collabora.com> AuthorDate: Thu Sep 3 16:04:19 2020 +0200 Commit: Jan Holesovsky <ke...@collabora.com> CommitDate: Thu Sep 3 16:07:42 2020 +0200 calc canvas: Temporarily disable the zoom animation. This way of the zoom animation will be removed; this creates a temporary layer and sets the "transition: transform 0.25s cubic-bezier(0,0,0.25,1);". So the browser decides what to do to transform it to the target transform, and finally the temporary layer is removed. With the canvas-based tile layer, we'll just abandon the animation when updating the zoom; and on mobile, we'll just keep re-rendering, it is supposed to be fast anyway - so at some stage, we'll just remove all the code related to this way of the zoom animation. Change-Id: I343969c203ac3611d269cdc69bfbc3f2f89fff35 diff --git a/loleaflet/src/map/anim/Map.ZoomAnimation.js b/loleaflet/src/map/anim/Map.ZoomAnimation.js index ddd38486f..5d6ceaec5 100644 --- a/loleaflet/src/map/anim/Map.ZoomAnimation.js +++ b/loleaflet/src/map/anim/Map.ZoomAnimation.js @@ -8,7 +8,7 @@ L.Map.mergeOptions({ zoomAnimationThreshold: 4 }); -var zoomAnimated = L.DomUtil.TRANSITION && L.Browser.any3d && !L.Browser.mobileOpera; +var zoomAnimated = false;//L.DomUtil.TRANSITION && L.Browser.any3d && !L.Browser.mobileOpera && !(this._docLayer instanceof L.CanvasTileLayer); if (zoomAnimated) { _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits