[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-4' - loleaflet/src

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Thu Mar 7 11:28:43 UTC 2019


 loleaflet/src/layer/tile/TileLayer.js |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

New commits:
commit 3645a9ce314f5bfafa78f2182084aa43e5e4f34e
Author:     Tor Lillqvist <tml at collabora.com>
AuthorDate: Thu Mar 7 13:26:22 2019 +0200
Commit:     Tor Lillqvist <tml at collabora.com>
CommitDate: Thu Mar 7 13:26:22 2019 +0200

    tdf#123874: Don't do the SVG preview thing in the iOS app as it crashes WebKit
    
    Sure, this is just a stopgap solution, it would be good to figure out
    a way to have the functionality working.

diff --git a/loleaflet/src/layer/tile/TileLayer.js b/loleaflet/src/layer/tile/TileLayer.js
index b4ab51f21..6932cc4f2 100644
--- a/loleaflet/src/layer/tile/TileLayer.js
+++ b/loleaflet/src/layer/tile/TileLayer.js
@@ -657,7 +657,12 @@ L.TileLayer = L.GridLayer.extend({
 							this._twipsToLatLng(topLeftTwips, this._map.getZoom()),
 							this._twipsToLatLng(bottomRightTwips, this._map.getZoom()));
 			this._graphicSelectionAngle = (strTwips.length === 5) ? parseInt(strTwips[4]) : 0;
-			this._map._socket.sendMessage('rendershapeselection mimetype=image/svg+xml');
+			// Workaround for tdf#123874. For some reason the handling of the
+			// shapeselectioncontent messages that we get back causes the WebKit process
+			// to crash on iOS.
+			if (!window.ThisIsTheiOSApp) {
+				this._map._socket.sendMessage('rendershapeselection mimetype=image/svg+xml');
+			}
 		}
 
 		this._onUpdateGraphicSelection();


More information about the Libreoffice-commits mailing list