Merge pull request #527 from ONLYOFFICE/fix/sheet-view
[SSE] Disable close view button for default sheet mode
This commit is contained in:
commit
2d6f7630c2
|
@ -115,6 +115,9 @@ define([
|
||||||
|
|
||||||
onSelectionChanged: function(info) {
|
onSelectionChanged: function(info) {
|
||||||
if (!this.toolbar.editMode || !this.view) return;
|
if (!this.toolbar.editMode || !this.view) return;
|
||||||
|
|
||||||
|
Common.Utils.lockControls(SSE.enumLock.sheetView, this.api.asc_getActiveNamedSheetView && !this.api.asc_getActiveNamedSheetView(this.api.asc_getActiveWorksheetIndex()),
|
||||||
|
{array: [this.view.btnCloseView]});
|
||||||
},
|
},
|
||||||
|
|
||||||
onFreeze: function(state) {
|
onFreeze: function(state) {
|
||||||
|
|
|
@ -97,7 +97,8 @@ define([
|
||||||
selSlicer: 'sel-slicer',
|
selSlicer: 'sel-slicer',
|
||||||
cantSort: 'cant-sort',
|
cantSort: 'cant-sort',
|
||||||
pivotLock: 'pivot-lock',
|
pivotLock: 'pivot-lock',
|
||||||
tableHasSlicer: 'table-has-slicer'
|
tableHasSlicer: 'table-has-slicer',
|
||||||
|
sheetView: 'sheet-view'
|
||||||
};
|
};
|
||||||
|
|
||||||
SSE.Views.Toolbar = Common.UI.Mixtbar.extend(_.extend({
|
SSE.Views.Toolbar = Common.UI.Mixtbar.extend(_.extend({
|
||||||
|
|
|
@ -114,7 +114,7 @@ define([
|
||||||
cls : 'btn-toolbar',
|
cls : 'btn-toolbar',
|
||||||
iconCls : 'toolbar__icon btn-sheet-view-close',
|
iconCls : 'toolbar__icon btn-sheet-view-close',
|
||||||
caption : this.textClose,
|
caption : this.textClose,
|
||||||
lock : [_set.coAuth, _set.lostConnect]
|
lock : [_set.sheetView, _set.coAuth, _set.lostConnect]
|
||||||
});
|
});
|
||||||
this.lockedControls.push(this.btnCloseView);
|
this.lockedControls.push(this.btnCloseView);
|
||||||
Common.Utils.injectComponent($host.find('#slot-closeview'), this.btnCloseView);
|
Common.Utils.injectComponent($host.find('#slot-closeview'), this.btnCloseView);
|
||||||
|
|
Loading…
Reference in a new issue