loleaflet/src/control/Control.MobileWizard.js |   13 +++++++++++++
 1 file changed, 13 insertions(+)

New commits:
commit eff3aa96a2fba6471a3873670586b7c991f6d7c0
Author:     Szymon Kłos <szymon.k...@collabora.com>
AuthorDate: Fri Dec 6 12:28:25 2019 +0100
Commit:     Szymon Kłos <szymon.k...@collabora.com>
CommitDate: Fri Dec 6 12:32:06 2019 +0100

    jsdialog: refresh sidebar just after started
    
    Temporary fix to allow showing of all widgets updated.
    In the initial JSON some values or controls are missing.
    This patch requests new JSON after current one was already received
    to get updated one.
    
    Change-Id: I74d0de7952d8ae8b86d8f6f9e9173e0a5b41b1c9

diff --git a/loleaflet/src/control/Control.MobileWizard.js 
b/loleaflet/src/control/Control.MobileWizard.js
index 5c5493ab3..f9df62535 100644
--- a/loleaflet/src/control/Control.MobileWizard.js
+++ b/loleaflet/src/control/Control.MobileWizard.js
@@ -191,8 +191,21 @@ L.Control.MobileWizard = L.Control.extend({
                this._currentPath = path;
        },
 
+       _refreshSidebar: function() {
+               var map = this.map;
+               setTimeout(function () {
+                       var message = 'dialogevent ' + window.sidebarId + ' 
{\"id\":\"-1\"}';
+                       map._socket.sendMessage(message);
+               }, 400);
+       },
+
        _onMobileWizard: function(data) {
                if (data) {
+                       var isSidebar = data.id !== 'menubar' && data.id !== 
'insertshape' && data.id !== 'funclist';
+
+                       if (!this._isActive && isSidebar)
+                               this._refreshSidebar();
+
                        this._isActive = true;
                        var currentPath = null;
                        if (this._currentPath)
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to