loleaflet/src/control/Control.DocumentNameInput.js |   14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)

New commits:
commit 824331364c3d3d4521f7ba85a71990600df17f81
Author:     Andras Timar <andras.ti...@collabora.com>
AuthorDate: Wed May 6 17:20:59 2020 +0200
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Wed May 6 17:45:26 2020 +0200

    Android: fix that app shows temporary file name "LibreOffice..."
    
    Change-Id: I5505b52f2fcf62ab8c99d0e5c7667a5e913b62dd
    Reviewed-on: https://gerrit.libreoffice.org/c/online/+/93577
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com>
    Reviewed-by: Andras Timar <andras.ti...@collabora.com>

diff --git a/loleaflet/src/control/Control.DocumentNameInput.js 
b/loleaflet/src/control/Control.DocumentNameInput.js
index 3e2b20ec2..e11d6bf95 100644
--- a/loleaflet/src/control/Control.DocumentNameInput.js
+++ b/loleaflet/src/control/Control.DocumentNameInput.js
@@ -52,22 +52,20 @@ L.Control.DocumentNameInput = L.Control.extend({
                        this.documentNameCancel();
                }
        },
-       
+
        onDocumentNameFocus: function() {
                // hide the caret in the main document
                this.map._onLostFocus();
        },
 
        onDocLayerInit: function() {
-               if (window.mode.isMobile() || window.mode.isTablet()) {
-                       if (!window.ThisIsAMobileApp)
-                               $('#document-name-input').hide();
-                       else
-                               $('#document-name-input').show();
+               // FIXME: Android app would display a temporary filename, not 
the actual filename
+               if (window.ThisIsTheAndroidApp) {
+                       $('#document-name-input').hide();
                } else {
                        $('#document-name-input').show();
                }
-       
+
                if (window.ThisIsAMobileApp) {
                        // We can now set the document name in the menu bar
                        $('#document-name-input').prop('disabled', false);
@@ -88,7 +86,7 @@ L.Control.DocumentNameInput = L.Control.extend({
                        // set the document name into the name field
                        $('#document-name-input').val(e.BaseFileName);
                }
-       
+
                if (e.UserCanNotWriteRelative === false) {
                        // Save As allowed
                        $('#document-name-input').prop('disabled', false);
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to