loleaflet/src/control/Control.Toolbar.js     |    3 ---
 loleaflet/src/layer/tile/CalcTileLayer.js    |    4 ++++
 loleaflet/src/layer/tile/ImpressTileLayer.js |    6 ++++++
 3 files changed, 10 insertions(+), 3 deletions(-)

New commits:
commit 1d1651795c73a7f2b73bdb17b7e2926047ffcbee
Author:     Szymon Kłos <[email protected]>
AuthorDate: Thu Apr 16 10:42:42 2020 +0200
Commit:     Szymon Kłos <[email protected]>
CommitDate: Thu Apr 16 11:11:34 2020 +0200

    Initialize sheets and formula bars only in Calc
    
    Change-Id: I4b27f21404e75ae22faa2bcf8a9dc27564f2dd56
    Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92337
    Tested-by: Jenkins CollaboraOffice <[email protected]>
    Reviewed-by: Szymon Kłos <[email protected]>

diff --git a/loleaflet/src/control/Control.Toolbar.js 
b/loleaflet/src/control/Control.Toolbar.js
index 5812d6a0b..529e0fa71 100644
--- a/loleaflet/src/control/Control.Toolbar.js
+++ b/loleaflet/src/control/Control.Toolbar.js
@@ -852,9 +852,7 @@ function createSigningBar() {
 
 function initNormalToolbar() {
        createMainToolbar();
-       map.addControl(L.control.formulaBar({showfunctionwizard: true}));
        createSigningBar();
-       map.addControl(L.control.sheetsBar({shownavigation: true}));
 }
 
 function setupSearchInput() {
diff --git a/loleaflet/src/layer/tile/CalcTileLayer.js 
b/loleaflet/src/layer/tile/CalcTileLayer.js
index bc4a30f3d..658b6362d 100644
--- a/loleaflet/src/layer/tile/CalcTileLayer.js
+++ b/loleaflet/src/layer/tile/CalcTileLayer.js
@@ -50,9 +50,13 @@ L.CalcTileLayer = L.TileLayer.extend({
                map.on('AnnotationCancel', this._onAnnotationCancel, this);
                map.on('AnnotationReply', this._onAnnotationReply, this);
                map.on('AnnotationSave', this._onAnnotationSave, this);
+
                if (window.mode.isMobile() || window.mode.isTablet()) {
                        this.onMobileInit(map);
                }
+
+               map.addControl(L.control.sheetsBar({shownavigation: true}));
+               map.addControl(L.control.formulaBar({showfunctionwizard: 
true}));
        },
 
        clearAnnotations: function () {
commit 6b0fbeda6b61421aaa179e018a1651d326f85736
Author:     Szymon Kłos <[email protected]>
AuthorDate: Thu Apr 16 10:42:03 2020 +0200
Commit:     Szymon Kłos <[email protected]>
CommitDate: Thu Apr 16 11:11:22 2020 +0200

    Initialize presentation bar only in Impress
    
    Change-Id: I50db46b0117b34cbbb0a95c59e8707be958c62a4
    Reviewed-on: https://gerrit.libreoffice.org/c/online/+/92336
    Tested-by: Jenkins CollaboraOffice <[email protected]>
    Reviewed-by: Szymon Kłos <[email protected]>

diff --git a/loleaflet/src/control/Control.Toolbar.js 
b/loleaflet/src/control/Control.Toolbar.js
index 428b4c74b..5812d6a0b 100644
--- a/loleaflet/src/control/Control.Toolbar.js
+++ b/loleaflet/src/control/Control.Toolbar.js
@@ -855,7 +855,6 @@ function initNormalToolbar() {
        map.addControl(L.control.formulaBar({showfunctionwizard: true}));
        createSigningBar();
        map.addControl(L.control.sheetsBar({shownavigation: true}));
-       map.addControl(L.control.presentationBar());
 }
 
 function setupSearchInput() {
diff --git a/loleaflet/src/layer/tile/ImpressTileLayer.js 
b/loleaflet/src/layer/tile/ImpressTileLayer.js
index 886509798..933a89c77 100644
--- a/loleaflet/src/layer/tile/ImpressTileLayer.js
+++ b/loleaflet/src/layer/tile/ImpressTileLayer.js
@@ -60,6 +60,8 @@ L.ImpressTileLayer = L.TileLayer.extend({
                        L.DomUtil.toBack(container);
                        map.addControl(L.control.partsPreview(container, 
preview, {fetchThumbnail: false}));
                        L.DomUtil.addClass(mobileWizardContent, 
'with-slide-sorter-above');
+               } else {
+                       this.onDesktopAndTabletInit(map);
                }
        },
 
@@ -113,6 +115,10 @@ L.ImpressTileLayer = L.TileLayer.extend({
                }
        },
 
+       onDesktopAndTabletInit: function(map) {
+               map.addControl(L.control.presentationBar());
+       },
+
        onMobileInit: function (map) {
                map.addControl(L.control.mobileTopBar('presentation'));
 
_______________________________________________
Libreoffice-commits mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to