From b16e82ea2eb7a7901678d0b650d2a919549233cb Mon Sep 17 00:00:00 2001 From: ShimaginAndrey Date: Wed, 4 Aug 2021 18:09:50 +0300 Subject: [PATCH] [SSE] Fix Bug 51707 --- .../spreadsheeteditor/mobile/src/controller/CellEditor.jsx | 7 +++++++ apps/spreadsheeteditor/mobile/src/view/CellEditor.jsx | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/apps/spreadsheeteditor/mobile/src/controller/CellEditor.jsx b/apps/spreadsheeteditor/mobile/src/controller/CellEditor.jsx index 1170be25b..06db117bf 100644 --- a/apps/spreadsheeteditor/mobile/src/controller/CellEditor.jsx +++ b/apps/spreadsheeteditor/mobile/src/controller/CellEditor.jsx @@ -6,16 +6,23 @@ const CellEditor = props => { useEffect(() => { Common.Notifications.on('engineCreated', api => { api.asc_registerCallback('asc_onSelectionNameChanged', onApiCellSelection.bind(this)); + api.asc_registerCallback('asc_onSelectionChanged', onApiSelectionChanged.bind(this)); }); }, []); const [cellName, setCellName] = useState(''); + const [stateCoauth, setCoauthDisabled] = useState(null); const onApiCellSelection = info => { setCellName(typeof(info)=='string' ? info : info.asc_getName()); }; + const onApiSelectionChanged = info => { + setCoauthDisabled(info.asc_getLocked() === true || info.asc_getLockedTable() === true || info.asc_getLockedPivotTable()===true); + } + return }; diff --git a/apps/spreadsheeteditor/mobile/src/view/CellEditor.jsx b/apps/spreadsheeteditor/mobile/src/view/CellEditor.jsx index 9367e06a9..9e914b4bd 100644 --- a/apps/spreadsheeteditor/mobile/src/view/CellEditor.jsx +++ b/apps/spreadsheeteditor/mobile/src/view/CellEditor.jsx @@ -23,7 +23,7 @@ const CellEditorView = props => { return