mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-05-21 19:35:38 +00:00
fix(mail(js)): map the NSLocale to the proper CKEditor locale
This commit is contained in:
@@ -43,7 +43,7 @@
|
||||
|
||||
// Set the locale of CKEditor
|
||||
this.localeCode = Preferences.defaults.LocaleCode;
|
||||
this.ckConfig = { language: Preferences.defaults.LocaleCode };
|
||||
this.ckConfig = { language: Preferences.defaults.ckLocaleCode };
|
||||
|
||||
this.composeType = Preferences.defaults.SOGoMailComposeMessageType;
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
'toolbar': [['Bold', 'Italic', '-', 'Link',
|
||||
'Font','FontSize','-','TextColor',
|
||||
'BGColor', 'Source']],
|
||||
language: defaults.LocaleCode
|
||||
language: defaults.ckLocaleCode
|
||||
};
|
||||
|
||||
if (!this.account.encryption)
|
||||
|
||||
@@ -163,6 +163,17 @@
|
||||
else
|
||||
data.SOGoContactsCategories = _.compact(data.SOGoContactsCategories);
|
||||
|
||||
if (data.LocaleCode) {
|
||||
switch (data.LocaleCode) {
|
||||
case 'sr_ME':
|
||||
case 'sr_RS':
|
||||
data.ckLocaleCode = 'sr-latn';
|
||||
break;
|
||||
default:
|
||||
data.ckLocaleCode = data.LocaleCode.replace('_', '-').toLowerCase();
|
||||
}
|
||||
}
|
||||
|
||||
angular.extend(_this.defaults, data);
|
||||
|
||||
// Configure date locale
|
||||
|
||||
Reference in New Issue
Block a user