Index: i18n.js |
=================================================================== |
--- a/i18n.js |
+++ b/i18n.js |
@@ -16,17 +16,17 @@ |
*/ |
"use strict"; |
// Getting UI locale cannot be done synchronously on Firefox, |
// requires messaging the background page. For Chrome and Safari, |
// we could get the UI locale here, but would need to duplicate |
// the logic implemented in Utils.appLocale. |
-chrome.runtime.sendMessage( |
+browser.runtime.sendMessage( |
{ |
type: "app.get", |
what: "localeInfo" |
}, |
(localeInfo) => |
{ |
document.documentElement.lang = localeInfo.locale; |
document.documentElement.dir = localeInfo.bidiDir; |
@@ -53,17 +53,17 @@ |
processString(match[4], currentElement); |
} |
else |
currentElement.appendChild(document.createTextNode(str)); |
} |
while (element.lastChild) |
element.removeChild(element.lastChild); |
- processString(chrome.i18n.getMessage(stringName, args), element); |
+ processString(browser.i18n.getMessage(stringName, args), element); |
} |
}; |
// Loads i18n strings |
function loadI18nStrings() |
{ |
function addI18nStringsToElements(containerElement) |
{ |