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

Unified Diff: ui/aura/window.cc

Issue 8574033: Beginnings of Window Modality support. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 1 month 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 | « ui/aura/client/aura_constants.cc ('k') | ui/aura_shell/aura_shell.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/window.cc
===================================================================
--- ui/aura/window.cc (revision 110305)
+++ ui/aura/window.cc (working copy)
@@ -56,17 +56,19 @@
if (transient_parent_)
transient_parent_->RemoveTransientChild(this);
- // Destroy transient children.
- Windows transient_children(transient_children_);
- STLDeleteElements(&transient_children);
- DCHECK(transient_children_.empty());
-
// And let the delegate do any post cleanup.
if (delegate_)
delegate_->OnWindowDestroyed();
if (parent_)
parent_->RemoveChild(this);
+ // Destroy transient children, only after we've removed ourselves from our
+ // parent, as destroying an active transient child may otherwise attempt to
+ // refocus us.
+ Windows transient_children(transient_children_);
+ STLDeleteElements(&transient_children);
+ DCHECK(transient_children_.empty());
+
FOR_EACH_OBSERVER(WindowObserver, observers_, OnWindowDestroyed(this));
}
« no previous file with comments | « ui/aura/client/aura_constants.cc ('k') | ui/aura_shell/aura_shell.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698