Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(120)

Unified Diff: ui/aura/root_window.cc

Issue 8816008: Remove aura::RootWindow instance from LayerAnimator::observers_ when the window is deleted (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review fix Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ui/aura_shell/shell_accelerator_controller_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/root_window.cc
diff --git a/ui/aura/root_window.cc b/ui/aura/root_window.cc
index bf646fcf0b0d279513965db3f1347098ab8e5d13..48d2798693f08439b1bbd2de22737fcfa6cab4f4 100644
--- a/ui/aura/root_window.cc
+++ b/ui/aura/root_window.cc
@@ -434,6 +434,8 @@ RootWindow::~RootWindow() {
// Make sure to destroy the compositor before terminating so that state is
// cleared and we don't hit asserts.
compositor_ = NULL;
+ // An observer may have been added by an animation on the RootWindow.
+ layer()->GetAnimator()->RemoveObserver(this);
#ifdef USE_WEBKIT_COMPOSITOR
if (!ui::Compositor::compositor_factory())
ui::CompositorCC::Terminate();
« no previous file with comments | « no previous file | ui/aura_shell/shell_accelerator_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698