[SSE] Hide spelling in view mode

This commit is contained in:
Julia Radzhabova 2019-08-06 14:27:47 +03:00
parent b7277ca39c
commit 0a27f876c9
4 changed files with 8 additions and 3 deletions

View file

@ -203,7 +203,10 @@ define([
this.leftMenu.btnComments.hide();
}
this.leftMenu.setOptionsPanel('spellcheck', this.getApplication().getController('Spellcheck').getView('Spellcheck'));
if (this.mode.isEdit) {
this.leftMenu.btnSpellcheck.show();
this.leftMenu.setOptionsPanel('spellcheck', this.getApplication().getController('Spellcheck').getView('Spellcheck'));
}
this.mode.trialMode && this.leftMenu.setDeveloperMode(this.mode.trialMode);
/** coauthoring end **/

View file

@ -702,7 +702,6 @@ define([
documentHolderController.setApi(me.api).loadConfig({config:me.editorConfig});
chatController.setApi(this.api).setMode(this.appOptions);
spellcheckController.setApi(this.api).setMode(this.appOptions);
statusbarController.createDelayedElements();
statusbarController.setApi(me.api);
@ -713,6 +712,8 @@ define([
this.formulaInput = celleditorController.getView('CellEditor').$el.find('textarea');
if (me.appOptions.isEdit) {
spellcheckController.setApi(me.api).setMode(me.appOptions);
if (me.appOptions.canAutosave) {
value = Common.localStorage.getItem("sse-settings-autosave");
if (value===null && me.appOptions.customization && me.appOptions.customization.autosave===false)

View file

@ -149,6 +149,7 @@ define([
disabled: true,
toggleGroup: 'leftMenuGroup'
});
this.btnSpellcheck.hide();
this.btnSpellcheck.on('click', _.bind(this.onBtnMenuClick, this));
this.btnSearch.on('click', _.bind(this.onBtnMenuClick, this));

View file

@ -143,7 +143,7 @@ define([
this.cmbDictionaryLanguage = new Common.UI.ComboBox({
el : $('#spellcheck-dictionary-language'),
style : 'width: 100%',
menuStyle : 'width: 100%;max-height: 200px;',
menuStyle : 'width: 100%;max-height: 163px;',
editable : false,
cls : 'input-group-nr'
});