зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1676897 - Remove obsolete resolutionchange handling from LightweightThemeConsumer.jsm. r=ntim
Differential Revision: https://phabricator.services.mozilla.com/D96838
This commit is contained in:
Родитель
ab81b1287a
Коммит
f59f6be9a5
|
@ -228,7 +228,6 @@ function LightweightThemeConsumer(aDocument) {
|
|||
);
|
||||
this._update(LightweightThemeManager.themeData);
|
||||
|
||||
this._win.addEventListener("resolutionchange", this);
|
||||
this._win.addEventListener("unload", this, { once: true });
|
||||
}
|
||||
|
||||
|
@ -255,13 +254,9 @@ LightweightThemeConsumer.prototype = {
|
|||
}
|
||||
|
||||
switch (aEvent.type) {
|
||||
case "resolutionchange":
|
||||
this._update(this._lastData);
|
||||
break;
|
||||
case "unload":
|
||||
Services.obs.removeObserver(this, "lightweight-theme-styling-update");
|
||||
Services.ppmm.sharedData.delete(`theme/${this._winId}`);
|
||||
this._win.removeEventListener("resolutionchange", this);
|
||||
this._win = this._doc = null;
|
||||
if (this.darkThemeMediaQuery) {
|
||||
this.darkThemeMediaQuery.removeListener(this);
|
||||
|
|
Загрузка…
Ссылка в новой задаче