From 2586e04148345d5f721fc02b764a448ae5b3b8ed Mon Sep 17 00:00:00 2001 From: Darshan-upadhyay1110 Date: Tue, 19 Sep 2023 17:24:58 +0530 Subject: [PATCH] Fix export as options on android app Some of the options seems to not working on mobile app Signed-off-by: Darshan-upadhyay1110 Change-Id: I934e446dfeeab46f26e95898522cb0b7c1cc64a2 --- browser/src/control/Control.Menubar.js | 36 +++++++++---------- .../src/control/Control.NotebookbarBuilder.js | 24 ++++++------- .../src/control/Control.NotebookbarCalc.js | 8 ++--- .../src/control/Control.NotebookbarDraw.js | 8 ++--- .../src/control/Control.NotebookbarImpress.js | 8 ++--- .../src/control/Control.NotebookbarWriter.js | 8 ++--- 6 files changed, 46 insertions(+), 46 deletions(-) diff --git a/browser/src/control/Control.Menubar.js b/browser/src/control/Control.Menubar.js index b7eb00c6174a..2b21995658d0 100644 --- a/browser/src/control/Control.Menubar.js +++ b/browser/src/control/Control.Menubar.js @@ -77,8 +77,8 @@ L.Control.Menubar = L.Control.extend({ {name: _('Share...'), id:'shareas', type: 'action'}, {name: _('See revision history'), id: 'rev-history', type: 'action'}, {name: !window.ThisIsAMobileApp ? _('Download as') : _('Export as'), id: 'downloadas', type: 'menu', menu: [ - {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', type: 'action'}, - {name: _('PDF Document (.pdf) as...'), id: !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf) as...'), id: 'exportpdf' , type: 'action'}, {name: _('ODF text document (.odt)'), id: 'downloadas-odt', type: 'action'}, {name: _('Word 2003 Document (.doc)'), id: 'downloadas-doc', type: 'action'}, {name: _('Word Document (.docx)'), id: 'downloadas-docx', type: 'action'}, @@ -384,8 +384,8 @@ L.Control.Menubar = L.Control.extend({ {name: _('Share...'), id:'shareas', type: 'action'}, {name: _('See revision history'), id: 'rev-history', type: 'action'}, {name: !window.ThisIsAMobileApp ? _('Download as') : _('Export as'), id: 'downloadas', type: 'menu', menu: [ - {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', type: 'action'}, - {name: _('PDF Document (.pdf) as...'), id: !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf) as...'), id: 'exportpdf' , type: 'action'}, {name: _('ODF presentation (.odp)'), id: 'downloadas-odp', type: 'action'}, {name: _('PowerPoint 2003 Presentation (.ppt)'), id: 'downloadas-ppt', type: 'action'}, {name: _('PowerPoint Presentation (.pptx)'), id: 'downloadas-pptx', type: 'action'}, @@ -534,8 +534,8 @@ L.Control.Menubar = L.Control.extend({ {name: _UNO('.uno:Print', 'presentation'), id: 'print', type: 'action'}, {name: _('See revision history'), id: 'rev-history', type: 'action'}, {name: !window.ThisIsAMobileApp ? _('Download as') : _('Export as'), id: 'downloadas', type: 'menu', menu: [ - {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', type: 'action'}, - {name: _('PDF Document (.pdf) as...'), id: !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf) as...'), id: 'exportpdf' , type: 'action'}, {name: _('ODF Drawing (.odg)'), id: 'downloadas-odg', type: 'action'} ]}, {name: _UNO('.uno:SetDocumentProperties', 'presentation'), uno: '.uno:SetDocumentProperties', id: 'properties'}, @@ -663,8 +663,8 @@ L.Control.Menubar = L.Control.extend({ {name: _('Share...'), id:'shareas', type: 'action'}, {name: _('See revision history'), id: 'rev-history', type: 'action'}, {name: !window.ThisIsAMobileApp ? _('Download as') : _('Export as'), id:'downloadas', type: 'menu', menu: [ - {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', type: 'action'}, - {name: _('PDF Document (.pdf) as...'), id: !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf) as...'), id: 'exportpdf' , type: 'action'}, {name: _('ODF spreadsheet (.ods)'), id: 'downloadas-ods', type: 'action'}, {name: _('Excel 2003 Spreadsheet (.xls)'), id: 'downloadas-xls', type: 'action'}, {name: _('Excel Spreadsheet (.xlsx)'), id: 'downloadas-xlsx', type: 'action'}, @@ -922,8 +922,8 @@ L.Control.Menubar = L.Control.extend({ ]}, {name: !window.ThisIsAMobileApp ? _('Download as') : _('Export as'), id: 'downloadas', type: 'menu', menu: [ - {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', type: 'action'}, - {name: _('PDF Document (.pdf) as...'), id: !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf) as...'), id: 'exportpdf', type: 'action'}, {name: _('ODF text document (.odt)'), id: 'downloadas-odt', type: 'action'}, {name: _('Word 2003 Document (.doc)'), id: 'downloadas-doc', type: 'action'}, {name: _('Word Document (.docx)'), id: 'downloadas-docx', type: 'action'}, @@ -987,8 +987,8 @@ L.Control.Menubar = L.Control.extend({ {name: _UNO('.uno:SetDocumentProperties', 'presentation'), uno: '.uno:SetDocumentProperties', id: 'properties'} ]}, {name: !window.ThisIsAMobileApp ? _('Download as') : _('Export as'), id:'downloadas', type: 'menu', menu: [ - {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', type: 'action'}, - {name: _('PDF Document (.pdf) as...'), id: !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf) as...'), id: 'exportpdf' , type: 'action'}, {name: _('ODF presentation (.odp)'), id: 'downloadas-odp', type: 'action'}, {name: _('PowerPoint 2003 Presentation (.ppt)'), id: 'downloadas-ppt', type: 'action'}, {name: _('PowerPoint Presentation (.pptx)'), id: 'downloadas-pptx', type: 'action'}, @@ -1051,8 +1051,8 @@ L.Control.Menubar = L.Control.extend({ {name: _UNO('.uno:SetDocumentProperties', 'presentation'), uno: '.uno:SetDocumentProperties', id: 'properties'} ]}, {name: !window.ThisIsAMobileApp ? _('Download as') : _('Export as'), id:'downloadas', type: 'menu', menu: [ - {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', type: 'action'}, - {name: _('PDF Document (.pdf) as...'), id: !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf) as...'), id: 'exportpdf', type: 'action'}, {name: _('ODF Drawing (.odg)'), id: 'downloadas-odg', type: 'action'} ]}, {name: _UNO('.uno:EditMenu', 'presentation'), id: 'editmenu', type: 'menu', menu: [ @@ -1109,8 +1109,8 @@ L.Control.Menubar = L.Control.extend({ {name: _UNO('.uno:SetDocumentProperties', 'spreadsheet'), uno: '.uno:SetDocumentProperties', id: 'properties'} ]}, {name: !window.ThisIsAMobileApp ? _('Download as') : _('Export as'), id:'downloadas', type: 'menu', menu: [ - {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', type: 'action'}, - {name: _('PDF Document (.pdf) as...'), id: !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf)'), id: !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', type: 'action'}, + {name: _('PDF Document (.pdf) as...'), id: 'exportpdf' , type: 'action'}, {name: _('ODF spreadsheet (.ods)'), id: 'downloadas-ods', type: 'action'}, {name: _('Excel 2003 Spreadsheet (.xls)'), id: 'downloadas-xls', type: 'action'}, {name: _('Excel Spreadsheet (.xlsx)'), id: 'downloadas-xlsx', type: 'action'} @@ -1288,8 +1288,8 @@ L.Control.Menubar = L.Control.extend({ allowedViewModeActions: [ 'savecomments', 'shareas', 'print', // file menu 'downloadas-odt', 'downloadas-doc', 'downloadas-docx', 'downloadas-rtf', // file menu - 'downloadas-odp', 'downloadas-ppt', 'downloadas-pptx', 'downloadas-odg', !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', // file menu - !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', !window.ThisIsAMobileApp ? 'exportepub' : 'downloadas-epub', // file menu + 'downloadas-odp', 'downloadas-ppt', 'downloadas-pptx', 'downloadas-odg', 'exportpdf' , // file menu + !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', !window.ThisIsAMobileApp ? 'exportepub' : 'downloadas-epub', // file menu 'downloadas-ods', 'downloadas-xls', 'downloadas-xlsx', 'downloadas-csv', 'closedocument', // file menu 'fullscreen', 'zoomin', 'zoomout', 'zoomreset', 'showstatusbar', 'togglemenubar', 'showresolved', 'toggledarktheme', // view menu 'about', 'keyboard-shortcuts', 'latestupdates', 'feedback', 'online-help', 'report-an-issue', // help menu diff --git a/browser/src/control/Control.NotebookbarBuilder.js b/browser/src/control/Control.NotebookbarBuilder.js index d481984c6451..38163e96c3c1 100644 --- a/browser/src/control/Control.NotebookbarBuilder.js +++ b/browser/src/control/Control.NotebookbarBuilder.js @@ -537,14 +537,14 @@ L.Control.NotebookbarBuilder = L.Control.JSDialogBuilder.extend({ 'command': !window.ThisIsAMobileApp ? 'exportepub' : 'downloadas-epub' }, { - 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'text': _('PDF Document (.pdf)'), - 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf' + 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf' }, { - 'id': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'id': 'exportpdf' , 'text': _('PDF Document (.pdf) as...'), - 'command': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf' + 'command': 'exportpdf' } ]; } else if (docType === 'spreadsheet') { @@ -566,14 +566,14 @@ L.Control.NotebookbarBuilder = L.Control.JSDialogBuilder.extend({ 'text': _('CSV File (.csv)') }, { - 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'text': _('PDF Document (.pdf)'), - 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf' + 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf' }, { - 'id': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'id': 'exportpdf' , 'text': _('PDF Document (.pdf) as...'), - 'command': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf' + 'command': 'exportpdf' } ]; } else if (docType === 'presentation') { @@ -595,14 +595,14 @@ L.Control.NotebookbarBuilder = L.Control.JSDialogBuilder.extend({ 'text': _('PowerPoint 2003 Presentation (.ppt)') }, { - 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'text': _('PDF Document (.pdf)'), - 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf' + 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf' }, { - 'id': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'id': 'exportpdf' , 'text': _('PDF Document (.pdf) as...'), - 'command': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf' + 'command': 'exportpdf' } ]; } diff --git a/browser/src/control/Control.NotebookbarCalc.js b/browser/src/control/Control.NotebookbarCalc.js index 62920d21a63c..e4af2605fb35 100644 --- a/browser/src/control/Control.NotebookbarCalc.js +++ b/browser/src/control/Control.NotebookbarCalc.js @@ -247,18 +247,18 @@ L.Control.NotebookbarCalc = L.Control.NotebookbarWriter.extend({ 'type': 'container', 'children': [ { - 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'type': 'customtoolitem', 'text': _('PDF Document (.pdf)'), - 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'inlineLabel': true, 'accessibility': { focusBack: true, combination: 'EP', de: null } }, { - 'id': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'id': 'exportpdf' , 'type': 'customtoolitem', 'text': _('PDF Document (.pdf) - Expert'), - 'command': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'command': 'exportpdf' , 'inlineLabel': true, 'accessibility': { focusBack: true, combination: 'ED', de: null } }, diff --git a/browser/src/control/Control.NotebookbarDraw.js b/browser/src/control/Control.NotebookbarDraw.js index 16257d2b0a4b..0daab3f703c1 100644 --- a/browser/src/control/Control.NotebookbarDraw.js +++ b/browser/src/control/Control.NotebookbarDraw.js @@ -247,20 +247,20 @@ L.Control.NotebookbarDraw = L.Control.NotebookbarImpress.extend({ 'type': 'container', 'children': [ { - 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'class': 'unoexportas', 'type': 'customtoolitem', 'text': _('PDF Document (.pdf)'), - 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'inlineLabel': true, 'accessibility': { focusBack: true, combination: 'EP', de: null } }, { - 'id': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'id': 'exportpdf' , 'class': 'unoexportas', 'type': 'customtoolitem', 'text': _('PDF Document (.pdf) - Expert'), - 'command': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'command': 'exportpdf' , 'inlineLabel': true, 'accessibility': { focusBack: true, combination: 'ES', de: null } }, diff --git a/browser/src/control/Control.NotebookbarImpress.js b/browser/src/control/Control.NotebookbarImpress.js index 533e47cab4ad..e0328af0c0b5 100644 --- a/browser/src/control/Control.NotebookbarImpress.js +++ b/browser/src/control/Control.NotebookbarImpress.js @@ -334,20 +334,20 @@ L.Control.NotebookbarImpress = L.Control.NotebookbarWriter.extend({ 'type': 'container', 'children': [ { - 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'class': 'unoexportpdf', 'type': 'customtoolitem', 'text': _('PDF Document (.pdf)'), - 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'inlineLabel': true, 'accessibility': { focusBack: true, combination: 'ED', de: null } }, { - 'id': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'id': 'exportpdf' , 'class': 'unoexportpdf', 'type': 'customtoolitem', 'text': _('PDF Document (.pdf) - Expert'), - 'command': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'command': 'exportpdf' , 'inlineLabel': true, 'accessibility': { focusBack: true, combination: 'DF', de: null } }, diff --git a/browser/src/control/Control.NotebookbarWriter.js b/browser/src/control/Control.NotebookbarWriter.js index 65d867090c63..e332c91e4075 100644 --- a/browser/src/control/Control.NotebookbarWriter.js +++ b/browser/src/control/Control.NotebookbarWriter.js @@ -284,17 +284,17 @@ L.Control.NotebookbarWriter = L.Control.Notebookbar.extend({ 'type': 'container', 'children': [ { - 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'id': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'type': 'customtoolitem', 'text': _('PDF Document (.pdf)'), - 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-direct-pdf', + 'command': !window.ThisIsAMobileApp ? 'exportdirectpdf' : 'downloadas-pdf', 'inlineLabel': true }, { - 'id': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'id': 'exportpdf' , 'type': 'customtoolitem', 'text': _('PDF Document (.pdf) - Expert'), - 'command': !window.ThisIsAMobileApp ? 'exportpdf' : 'downloadas-pdf', + 'command': 'exportpdf' , 'inlineLabel': true }, ],