mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 846186 - Tilt error flooding error console (TypeError: mouseLerp is undefined), r=rcampbell
This commit is contained in:
parent
634a19638b
commit
a9a9729e97
@ -1127,7 +1127,11 @@ TiltVisualizer.Presenter.prototype = {
|
||||
|
||||
TiltUtils.destroyObject(this._renderer);
|
||||
|
||||
this.contentWindow.removeEventListener("resize", this._onResize, false);
|
||||
// Closing the tab would result in contentWindow being a dead object,
|
||||
// so operations like removing event listeners won't work anymore.
|
||||
if (this.contentWindow == this.chromeWindow.content) {
|
||||
this.contentWindow.removeEventListener("resize", this._onResize, false);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@ -1232,7 +1236,11 @@ TiltVisualizer.Controller.prototype = {
|
||||
canvas.removeEventListener("keypress", this._onKeyPress, true);
|
||||
canvas.removeEventListener("blur", this._onBlur, false);
|
||||
|
||||
presenter.contentWindow.removeEventListener("resize", this._onResize, false);
|
||||
// Closing the tab would result in contentWindow being a dead object,
|
||||
// so operations like removing event listeners won't work anymore.
|
||||
if (presenter.contentWindow == presenter.chromeWindow.content) {
|
||||
presenter.contentWindow.removeEventListener("resize", this._onResize, false);
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user