Skip to content

Commit

Permalink
Hide context menu items that don't work on mobile
Browse files Browse the repository at this point in the history
- Page Style, Paste Special don't work
- Group/Ungroup Sparklines should be hidden when they aren't
  relevant, let's hide completely for now

Signed-off-by: Aron Budea <aron.budea@collabora.com>
Change-Id: Iae7da11719827512307eeeade10caa56e023c8f0
  • Loading branch information
thebearon authored and pedropintosilva committed Sep 19, 2022
1 parent 58cd55e commit 384b4ce
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions browser/src/control/Control.ContextMenu.js
Expand Up @@ -39,7 +39,7 @@ L.Control.ContextMenu = L.Control.extend({
'FormatStockGain', 'InsertDataLabel' , 'DeleteDataLabel', 'ResetDataPoint',
'InsertTrendline', 'InsertMeanValue', 'InsertXErrorBars' , 'InsertYErrorBars', 'ResetAllDataPoints' , 'DeleteAxis',
'InsertAxisTitle', 'InsertMinorGrid', 'InsertMajorGrid' , 'InsertAxis', 'DeleteMajorGrid' , 'DeleteMinorGrid',
'SpellCheckIgnoreAll', 'LanguageStatus', 'SpellCheckApplySuggestion','PageDialog',
'SpellCheckIgnoreAll', 'LanguageStatus', 'SpellCheckApplySuggestion', 'PageDialog',
'CompressGraphic', 'GraphicDialog', 'InsertCaptionDialog',
'NextTrackedChange', 'PreviousTrackedChange', 'RejectTrackedChange', 'AcceptTrackedChange'],

Expand Down Expand Up @@ -72,6 +72,7 @@ L.Control.ContextMenu = L.Control.extend({
// lines as in the arrays above.
mobileBlackList: [
// general
'PasteSpecial',
'TransformDialog', 'FormatLine', 'FormatArea',
'InsertTitles', 'InsertRemoveAxes',
'DiagramType', 'DataRanges',
Expand All @@ -80,10 +81,12 @@ L.Control.ContextMenu = L.Control.extend({
'InsertTrendline', 'InsertXErrorBars' , 'InsertYErrorBars', 'FormatChartArea',
'FormatMeanValue', 'DiagramData', 'FormatLegend', 'FormatTrendline',
'FormatTrendlineEquation', 'FormatStockLoss', 'FormatStockGain', 'LanguageStatus',
'PageDialog',
// text
'SpellingAndGrammarDialog', 'FontDialog', 'FontDialogForParagraph',
// spreadsheet
'FormatCellDialog', 'DataDataPilotRun'
'FormatCellDialog', 'DataDataPilotRun',
'GroupSparklines', 'UngroupSparklines'
]
},

Expand Down

0 comments on commit 384b4ce

Please sign in to comment.