☠☠ backed out by b560bd9c4c8f ☠ ☠ | |
author | Zibi Braniecki <zbraniecki@mozilla.com> |
Tue, 19 May 2020 16:27:36 +0000 | |
changeset 530827 | 90972e768c3397c5816ceaa8bb8c702b432f2166 |
parent 530826 | 5571b75d82b66bad47fe582fb1d1f671254cd6fa |
child 530828 | 7d5a3d1035dc4283912d270549a0532fee02bc0d |
push id | 37433 |
push user | dluca@mozilla.com |
push date | Wed, 20 May 2020 03:39:31 +0000 |
treeherder | mozilla-central@855249e545c3 [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | stas |
bugs | 1631593 |
milestone | 78.0a1 |
first release with | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
last release without | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
--- a/intl/l10n/Localization.jsm +++ b/intl/l10n/Localization.jsm @@ -489,47 +489,16 @@ class Localization { * @returns {string?} * @private */ formatValueSync(id, args) { const [val] = this.formatValuesSync([{id, args}]); return val; } - /** - * Register weak observers on events that will trigger cache invalidation - */ - registerObservers() { - Services.obs.addObserver(this, "intl:app-locales-changed", true); - Services.prefs.addObserver("intl.l10n.pseudo", this, true); - } - - /** - * Default observer handler method. - * - * @param {String} subject - * @param {String} topic - * @param {Object} data - */ - observe(subject, topic, data) { - switch (topic) { - case "intl:app-locales-changed": - this.onChange(); - break; - case "nsPref:changed": - switch (data) { - case "intl.l10n.pseudo": - this.onChange(); - } - break; - default: - break; - } - } - onChange() { if (this.bundles) { this.regenerateBundles(false); } } /** * This method should be called when there's a reason to believe