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

Unified Diff: ui/aura/window.cc

Issue 1910483002: Makes aura::LayoutManager be destroyed before properties (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comment Created 4 years, 8 months 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/window_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/window.cc
diff --git a/ui/aura/window.cc b/ui/aura/window.cc
index 0b405d21f924e19790a56d42193a95fad541da4e..845373aa8baa3b7a75262ba6830075cbfc97d994 100644
--- a/ui/aura/window.cc
+++ b/ui/aura/window.cc
@@ -150,6 +150,10 @@ Window::~Window() {
observer->OnWindowDestroyed(this);
}
+ // Delete the LayoutManager before properties. This way if the LayoutManager
+ // depends upon properties existing the properties are still valid.
+ layout_manager_.reset();
+
// Clear properties.
for (std::map<const void*, Value>::const_iterator iter = prop_map_.begin();
iter != prop_map_.end();
« no previous file with comments | « no previous file | ui/aura/window_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698