From febe1fd66f47f8e37e801ab2f25d1aad722e67b1 Mon Sep 17 00:00:00 2001 From: "oshima@chromium.org" Date: Wed, 7 Aug 2013 16:07:24 +0000 Subject: Delete EmptyWindowDelegate when window is destroyed This should fix leaks reported on memory bots. TBR=jyasskin@chromium.org BUG=none Review URL: https://codereview.chromium.org/22299006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@216200 0039d316-1c4b-4281-b951-d872f2087c98 --- ash/root_window_controller.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'ash/root_window_controller.cc') diff --git a/ash/root_window_controller.cc b/ash/root_window_controller.cc index 284c39e..6d5fb62 100644 --- a/ash/root_window_controller.cc +++ b/ash/root_window_controller.cc @@ -179,7 +179,9 @@ class EmptyWindowDelegate : public aura::WindowDelegate { float device_scale_factor) OVERRIDE { } virtual void OnWindowDestroying() OVERRIDE {} - virtual void OnWindowDestroyed() OVERRIDE {} + virtual void OnWindowDestroyed() OVERRIDE { + delete this; + } virtual void OnWindowTargetVisibilityChanged(bool visible) OVERRIDE { } virtual bool HasHitTestMask() const OVERRIDE { -- cgit v1.1