mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Fix for Menu component memory leak (#6526)
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com> Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
1 parent
19aeda0241
commit
82ab60d544
1 file changed
+2
@@ -136,6 +136,8 @@ class NonInjectedMenu extends React.Component<MenuProps & Dependencies, State> {
|
|||||||
window.removeEventListener("resize", this.onWindowResize);
|
window.removeEventListener("resize", this.onWindowResize);
|
||||||
window.removeEventListener("click", this.onClickOutside, true);
|
window.removeEventListener("click", this.onClickOutside, true);
|
||||||
window.removeEventListener("scroll", this.onScrollOutside, true);
|
window.removeEventListener("scroll", this.onScrollOutside, true);
|
||||||
|
window.removeEventListener("blur", this.onBlur, true);
|
||||||
|
window.removeEventListener("contextmenu", this.onContextMenu, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
componentDidUpdate(prevProps: MenuProps) {
|
componentDidUpdate(prevProps: MenuProps) {
|
||||||
|
|||||||
Reference in new issue
Block a user