loleaflet/src/map/handler/Map.SlideShow.js | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-)
New commits: commit 6f3f52304f122036e1bc405a8882d9a6ef1a90d1 Author: Jan Holesovsky <ke...@collabora.com> AuthorDate: Mon Feb 24 21:49:27 2020 +0100 Commit: Andras Timar <andras.ti...@collabora.com> CommitDate: Tue Feb 25 21:03:37 2020 +0100 Don't bind the slideshow downloading to the richdocuments... ... decide based on the DownloadAsPostMessage wopi value instead. The idea is that the Nextcloud app actually sets the DownloadAsPostMessage wopi value to true, which means that all the downloading (including slideshow) is passed as Download_As postMessage anyway. So deciding here based on the existence of the Nextcloud app is not necessary, because there might be others who set the DownloadAsPostMessage and rely on the Download_As postMessage, but would get a non-functional iframe over the top of the editing window. Change-Id: I4a5c1d9ef6276908a1b3910a4269091955cdc490 Reviewed-on: https://gerrit.libreoffice.org/c/online/+/89382 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com> Reviewed-by: Andras Timar <andras.ti...@collabora.com> diff --git a/loleaflet/src/map/handler/Map.SlideShow.js b/loleaflet/src/map/handler/Map.SlideShow.js index 4f268df24..0a1987707 100644 --- a/loleaflet/src/map/handler/Map.SlideShow.js +++ b/loleaflet/src/map/handler/Map.SlideShow.js @@ -29,7 +29,7 @@ L.Map.SlideShow = L.Handler.extend({ return; } - if (!window.RichDocumentsMobileInterface) { + if (!this._map['wopi'].DownloadAsPostMessage) { this._slideShow = L.DomUtil.create('iframe', 'leaflet-slideshow', this._map._container); if (this._slideShow.requestFullscreen) { this._slideShow.requestFullscreen(); @@ -53,7 +53,7 @@ L.Map.SlideShow = L.Handler.extend({ }, _onFullScreenChange: function () { - if (window.RichDocumentsMobileInterface) { + if (this._map['wopi'].DownloadAsPostMessage) { return; } @@ -67,12 +67,8 @@ L.Map.SlideShow = L.Handler.extend({ }, _onSlideDownloadReady: function (e) { - if (window.RichDocumentsMobileInterface) { - window.RichDocumentsMobileInterface.slideShow(e.url); - } else { - this._slideShow.src = e.url; - this._slideShow.contentWindow.focus(); - } + this._slideShow.src = e.url; + this._slideShow.contentWindow.focus(); } }); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits