[SSE] Fix Bug 42390 (#237)

This commit is contained in:
Julia Radzhabova 2019-08-28 17:19:53 +03:00 committed by Alexey Golubev
parent 35bfd092a0
commit f4f007c5d6

View file

@ -56,18 +56,6 @@ define([
sdkViewName : '#id_main',
initialize: function () {
this.addListeners({
'DataTab': {
'data:group': this.onGroup,
'data:ungroup': this.onUngroup,
'data:tocolumns': this.onTextToColumn,
'data:show': this.onShowClick,
'data:hide': this.onHideClick,
'data:groupsettings': this.onGroupSettings
}
});
this._state = {
CSVOptions: new Asc.asc_CTextOptions(0, 4, '')
};
@ -91,6 +79,19 @@ define([
this.view = this.createView('DataTab', {
toolbar: this.toolbar.toolbar
});
this.addListeners({
'DataTab': {
'data:group': this.onGroup,
'data:ungroup': this.onUngroup,
'data:tocolumns': this.onTextToColumn,
'data:show': this.onShowClick,
'data:hide': this.onHideClick,
'data:groupsettings': this.onGroupSettings
},
'Statusbar': {
'sheet:changed': this.onApiSheetChanged
}
});
},
SetDisabled: function(state) {
@ -217,6 +218,13 @@ define([
}
},
onApiSheetChanged: function() {
if (!this.toolbar.mode || !this.toolbar.mode.isEdit || this.toolbar.mode.isEditDiagram || this.toolbar.mode.isEditMailMerge) return;
var currentSheet = this.api.asc_getActiveWorksheetIndex();
this.onWorksheetLocked(currentSheet, this.api.asc_isWorksheetLockedOrDeleted(currentSheet));
},
textWizard: 'Text to Columns Wizard'
}, SSE.Controllers.DataTab || {}));