[SSE] Fix Bug 32955.

This commit is contained in:
Julia Radzhabova 2016-08-16 15:32:12 +03:00
parent 84cf8d181a
commit 58b7c3f97c
2 changed files with 11 additions and 12 deletions

View file

@ -117,11 +117,13 @@ define([
},
onApiEditCell: function(state) {
if (state == Asc.c_oAscCellEditorState.editStart)
if (state == Asc.c_oAscCellEditorState.editStart){
this.api.isCellEdited = true;
else if (state == Asc.c_oAscCellEditorState.editEnd) {
this.editor.cellNameDisabled(true);
} else if (state == Asc.c_oAscCellEditorState.editEnd) {
this.api.isCellEdited = false;
this.api.isCEditorFocused = false;
this.editor.cellNameDisabled(false);
}
},
@ -144,16 +146,7 @@ define([
},
onCellsRange: function(status) {
var isRangeSelection = (status != Asc.c_oAscSelectionDialogType.None);
if (isRangeSelection) {
this.editor.$cellname.attr('disabled', 'disabled');
this.editor.$btnfunc['addClass']('disabled');
} else {
this.editor.$cellname.removeAttr('disabled');
this.editor.$btnfunc['removeClass']('disabled');
}
this.editor.btnNamedRanges.setDisabled(isRangeSelection);
this.editor.cellNameDisabled(status != Asc.c_oAscSelectionDialogType.None);
},
onLayoutResize: function(o, r) {

View file

@ -100,6 +100,12 @@ define([
}
},
cellNameDisabled: function(disabled){
(disabled) ? this.$cellname.attr('disabled', 'disabled') : this.$cellname.removeAttr('disabled');
this.$btnfunc.toggleClass('disabled', disabled);
this.btnNamedRanges.setDisabled(disabled);
},
tipFormula: 'Insert Function',
textManager: 'Manager'
}, SSE.Views.CellEditor || {}));