[Libreoffice-commits] online.git: loleaflet/js
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Wed Mar 6 02:06:20 UTC 2019
loleaflet/js/global.js | 8 ++++++++
1 file changed, 8 insertions(+)
New commits:
commit 304852ccd5ad8086d43728c830534eb53ac191dc
Author: Henry Castro <hcastro at collabora.com>
AuthorDate: Sun Feb 10 19:15:25 2019 -0400
Commit: Henry Castro <hcastro at collabora.com>
CommitDate: Tue Mar 5 22:05:51 2019 -0400
loleaflet: fix String.locale assignment
Change-Id: I901f635ef2cb176329ef8e836a5314efabbc026b
diff --git a/loleaflet/js/global.js b/loleaflet/js/global.js
index d384409f0..b6b1c7bd4 100644
--- a/loleaflet/js/global.js
+++ b/loleaflet/js/global.js
@@ -26,6 +26,14 @@
return results === null ? '' : results[1].replace(/\+/g, ' ');
};
+ var lang = self.getParameterByName('lang');
+ if (lang) {
+ String.locale = lang;
+ }
+ else {
+ String.locale = 'en';
+ }
+
global._ = function (string) {
// In the mobile app case we can't use the stuff from l10n-for-node, as that assumes HTTP.
if (window.ThisIsTheiOSApp) {
More information about the Libreoffice-commits
mailing list