mirror of
https://github.com/ONLYOFFICE/web-apps.git
synced 2026-07-25 14:36:49 +08:00
[DE PE SSE] Add alert when RTL interface setting was changed
This commit is contained in:
@ -992,6 +992,7 @@ define([
|
||||
}
|
||||
|
||||
Common.localStorage.setItem("de-settings-paste-button", this.chPaste.isChecked() ? 1 : 0);
|
||||
var isRtlChanged = this.chRTL.$el.is(':visible') && Common.localStorage.getBool("ui-rtl") !== this.chRTL.isChecked();
|
||||
Common.localStorage.setBool("ui-rtl", this.chRTL.isChecked());
|
||||
Common.localStorage.setBool("de-settings-quick-print-button", this.chQuickPrint.isChecked());
|
||||
|
||||
@ -1003,6 +1004,16 @@ define([
|
||||
if (this._oldUnits !== this.cmbUnit.getValue())
|
||||
Common.NotificationCenter.trigger('settings:unitschanged', this);
|
||||
}
|
||||
|
||||
if (isRtlChanged) {
|
||||
var config = {
|
||||
title: this.txtWorkspaceSettingChange,
|
||||
msg: this.txtRestartEditor,
|
||||
iconCls: 'warn',
|
||||
buttons: ['ok']
|
||||
};
|
||||
Common.UI.alert(config);
|
||||
}
|
||||
},
|
||||
|
||||
fillShowChanges: function(fastmode) {
|
||||
@ -1095,7 +1106,9 @@ define([
|
||||
strShowOthersChanges: 'Show changes from other users',
|
||||
txtAdvancedSettings: 'Advanced Settings',
|
||||
txtQuickPrint: 'Show the Quick Print button in the editor header',
|
||||
txtQuickPrintTip: 'The document will be printed on the last selected or default printer'
|
||||
txtQuickPrintTip: 'The document will be printed on the last selected or default printer',
|
||||
txtWorkspaceSettingChange: 'Workspace setting (RTL interface) change',
|
||||
txtRestartEditor: 'Please restart document editor so that your workspace settings can take effect'
|
||||
}, DE.Views.FileMenuPanels.Settings || {}));
|
||||
|
||||
DE.Views.FileMenuPanels.RecentFiles = Common.UI.BaseView.extend({
|
||||
|
||||
@ -791,6 +791,7 @@ define([
|
||||
Common.Utils.InternalSettings.set("pe-macros-mode", this.cmbMacros.getValue());
|
||||
|
||||
Common.localStorage.setItem("pe-settings-paste-button", this.chPaste.isChecked() ? 1 : 0);
|
||||
var isRtlChanged = this.chRTL.$el.is(':visible') && Common.localStorage.getBool("ui-rtl") !== this.chRTL.isChecked();
|
||||
Common.localStorage.setBool("ui-rtl", this.chRTL.isChecked());
|
||||
Common.localStorage.setBool("pe-settings-quick-print-button", this.chQuickPrint.isChecked());
|
||||
|
||||
@ -802,6 +803,16 @@ define([
|
||||
if (this._oldUnits !== this.cmbUnit.getValue())
|
||||
Common.NotificationCenter.trigger('settings:unitschanged', this);
|
||||
}
|
||||
|
||||
if (isRtlChanged) {
|
||||
var config = {
|
||||
title: this.txtWorkspaceSettingChange,
|
||||
msg: this.txtRestartEditor,
|
||||
iconCls: 'warn',
|
||||
buttons: ['ok']
|
||||
};
|
||||
Common.UI.alert(config);
|
||||
}
|
||||
},
|
||||
|
||||
onFontRenderSelected: function(combo, record) {
|
||||
@ -872,7 +883,9 @@ define([
|
||||
strShowOthersChanges: 'Show changes from other users',
|
||||
txtAdvancedSettings: 'Advanced Settings',
|
||||
txtQuickPrint: 'Show the Quick Print button in the editor header',
|
||||
txtQuickPrintTip: 'The document will be printed on the last selected or default printer'
|
||||
txtQuickPrintTip: 'The document will be printed on the last selected or default printer',
|
||||
txtWorkspaceSettingChange: 'Workspace setting (RTL interface) change',
|
||||
txtRestartEditor: 'Please restart presentation editor so that your workspace settings can take effect'
|
||||
}, PE.Views.FileMenuPanels.Settings || {}));
|
||||
|
||||
PE.Views.FileMenuPanels.RecentFiles = Common.UI.BaseView.extend({
|
||||
|
||||
@ -1069,6 +1069,7 @@ define([
|
||||
Common.Utils.InternalSettings.set("sse-macros-mode", this.cmbMacros.getValue());
|
||||
|
||||
Common.localStorage.setItem("sse-settings-paste-button", this.chPaste.isChecked() ? 1 : 0);
|
||||
var isRtlChanged = this.chRTL.$el.is(':visible') && Common.localStorage.getBool("ui-rtl") !== this.chRTL.isChecked();
|
||||
Common.localStorage.setBool("ui-rtl", this.chRTL.isChecked());
|
||||
Common.localStorage.setBool("sse-settings-quick-print-button", this.chQuickPrint.isChecked());
|
||||
|
||||
@ -1103,6 +1104,16 @@ define([
|
||||
|
||||
if (this.mode.isEdit)
|
||||
this.api.asc_setDate1904(this.chDateSystem.isChecked());
|
||||
|
||||
if (isRtlChanged) {
|
||||
var config = {
|
||||
title: this.txtWorkspaceSettingChange,
|
||||
msg: this.txtRestartEditor,
|
||||
iconCls: 'warn',
|
||||
buttons: ['ok']
|
||||
};
|
||||
Common.UI.alert(config);
|
||||
}
|
||||
},
|
||||
|
||||
updateRegionalExample: function(landId) {
|
||||
@ -1267,7 +1278,9 @@ define([
|
||||
strDateFormat1904: 'Use 1904 date system',
|
||||
txtAdvancedSettings: 'Advanced Settings',
|
||||
txtQuickPrint: 'Show the Quick Print button in the editor header',
|
||||
txtQuickPrintTip: 'The document will be printed on the last selected or default printer'
|
||||
txtQuickPrintTip: 'The document will be printed on the last selected or default printer',
|
||||
txtWorkspaceSettingChange: 'Workspace setting (RTL interface) change',
|
||||
txtRestartEditor: 'Please restart spreadsheet editor so that your workspace settings can take effect'
|
||||
|
||||
}, SSE.Views.FileMenuPanels.MainSettingsGeneral || {}));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user