From 27c29389e01c1661c82b2c6117c6cf3cfe639ff8 Mon Sep 17 00:00:00 2001 From: ShimaginAndrey Date: Wed, 6 Oct 2021 13:23:47 +0300 Subject: [PATCH] [SSE] Fix Bug 52936 --- .../mobile/src/controller/CellEditor.jsx | 16 +++++++++++++--- .../mobile/src/view/CellEditor.jsx | 2 +- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/apps/spreadsheeteditor/mobile/src/controller/CellEditor.jsx b/apps/spreadsheeteditor/mobile/src/controller/CellEditor.jsx index 9f41efbd5..f67658762 100644 --- a/apps/spreadsheeteditor/mobile/src/controller/CellEditor.jsx +++ b/apps/spreadsheeteditor/mobile/src/controller/CellEditor.jsx @@ -14,7 +14,7 @@ const CellEditor = props => { }, []); const [cellName, setCellName] = useState(''); - const [stateCoauth, setCoauthDisabled] = useState(null); + const [stateFunctions, setFunctionshDisabled] = useState(null); const [stateFuncArr, setFuncArr] = useState(''); const onApiCellSelection = info => { @@ -22,7 +22,17 @@ const CellEditor = props => { }; const onApiSelectionChanged = info => { - setCoauthDisabled(info.asc_getLocked() === true || info.asc_getLockedTable() === true || info.asc_getLockedPivotTable()===true); + let seltype = info.asc_getSelectionType(), + coauth_disable = info.asc_getLocked() === true || info.asc_getLockedTable() === true || info.asc_getLockedPivotTable()===true; + + let is_chart_text = seltype == Asc.c_oAscSelectionType.RangeChartText, + is_chart = seltype == Asc.c_oAscSelectionType.RangeChart, + is_shape_text = seltype == Asc.c_oAscSelectionType.RangeShapeText, + is_shape = seltype == Asc.c_oAscSelectionType.RangeShape, + is_image = seltype == Asc.c_oAscSelectionType.RangeImage || seltype == Asc.c_oAscSelectionType.RangeSlicer, + is_mode_2 = is_shape_text || is_shape || is_chart_text || is_chart; + + setFunctionshDisabled(is_image || is_mode_2 || coauth_disable); } const onFormulaCompleteMenu = funcArr => { @@ -43,7 +53,7 @@ const CellEditor = props => { return ( {