mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 13:21:05 +00:00
Bug 1660392 - [l10nregistry] part6: Move Localization to use WebIDL L10nRegistry. r=platform-i18n-reviewers,nordzilla
Depends on D102372 Differential Revision: https://phabricator.services.mozilla.com/D105416
This commit is contained in:
parent
ded73fe965
commit
1eead2ccc2
@ -21,7 +21,6 @@
|
||||
/* eslint no-console: ["error", { allow: ["warn", "error"] }] */
|
||||
/* global console */
|
||||
|
||||
const { L10nRegistry } = ChromeUtils.import("resource://gre/modules/L10nRegistry.jsm");
|
||||
const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
|
||||
const { AppConstants } = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");
|
||||
|
||||
@ -183,12 +182,12 @@ class CachedSyncIterable extends CachedIterable {
|
||||
*/
|
||||
function defaultGenerateBundles(resourceIds) {
|
||||
const appLocales = Services.locale.appLocalesAsBCP47;
|
||||
return L10nRegistry.generateBundles(appLocales, resourceIds);
|
||||
return L10nRegistry.getInstance().generateBundles(appLocales, resourceIds);
|
||||
}
|
||||
|
||||
function defaultGenerateBundlesSync(resourceIds) {
|
||||
const appLocales = Services.locale.appLocalesAsBCP47;
|
||||
return L10nRegistry.generateBundlesSync(appLocales, resourceIds);
|
||||
return L10nRegistry.getInstance().generateBundlesSync(appLocales, resourceIds);
|
||||
}
|
||||
|
||||
function maybeReportErrorToGecko(error) {
|
||||
|
Loading…
Reference in New Issue
Block a user