Revert "loleaflet: load l10n files according to parameter "lang""
This reverts commit 668b837c70
.
This commit is contained in:
parent
153e2d06fa
commit
b842679e9a
2 changed files with 7 additions and 9 deletions
|
@ -18,7 +18,6 @@ var
|
|||
undef_type = "undefined"
|
||||
, string_type = "string"
|
||||
, nav = {}
|
||||
, lang = {}
|
||||
, String_ctr = String
|
||||
, has_own_prop = Object.prototype.hasOwnProperty
|
||||
, load_queues = {}
|
||||
|
@ -189,7 +188,6 @@ var
|
|||
try
|
||||
{
|
||||
nav = self.navigator;
|
||||
lang = self.getParameterByName('lang');
|
||||
}
|
||||
catch(selfNotFoundException)
|
||||
{
|
||||
|
@ -242,7 +240,7 @@ if (!browserless && typeof XMLHttpRequest === undef_type && typeof ActiveXObject
|
|||
}
|
||||
|
||||
String_ctr[$default_locale] = String_ctr[$default_locale] || "";
|
||||
String_ctr[$locale] = nav && lang && (lang) || "en";
|
||||
String_ctr[$locale] = nav && (nav.language || nav.userLanguage) || "";
|
||||
|
||||
if (!browserless || typeof document !== undef_type) {
|
||||
var
|
||||
|
@ -270,11 +268,6 @@ if (!browserless || typeof document !== undef_type) {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
load(self.__globalL10n);
|
||||
load(self.__locoreL10n);
|
||||
load(self.__helpL10n);
|
||||
load(self.__unoL10n);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -1,10 +1,15 @@
|
|||
/* -*- js-indent-level: 8 -*- */
|
||||
|
||||
/* global vex _ */
|
||||
/* global vex _ getParameterByName */
|
||||
var errorMessages = {};
|
||||
|
||||
vex.defaultOptions.className = 'vex-theme-plain';
|
||||
|
||||
var lang = getParameterByName('lang');
|
||||
if (lang) {
|
||||
String.locale = lang;
|
||||
}
|
||||
|
||||
errorMessages.diskfull = _('No disk space left on server, please contact the server administrator to continue.');
|
||||
errorMessages.emptyhosturl = _('The host URL is empty. The loolwsd server is probably misconfigured, please contact the administrator.');
|
||||
errorMessages.limitreached = _('This is an unsupported version of {productname}. To avoid the impression that it is suitable for deployment in enterprises, this message appears when more than {docs} documents or {connections} connections are in use concurrently');
|
||||
|
|
Loading…
Reference in a new issue