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

Side by Side Diff: Source/core/frame/LocalFrame.cpp

Issue 335573004: Oilpan: Notify supplements of Page and LocalFrame destruction. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org>
3 * 1999 Lars Knoll <knoll@kde.org> 3 * 1999 Lars Knoll <knoll@kde.org>
4 * 1999 Antti Koivisto <koivisto@kde.org> 4 * 1999 Antti Koivisto <koivisto@kde.org>
5 * 2000 Simon Hausmann <hausmann@kde.org> 5 * 2000 Simon Hausmann <hausmann@kde.org>
6 * 2000 Stefan Schimanski <1Stein@gmx.de> 6 * 2000 Stefan Schimanski <1Stein@gmx.de>
7 * 2001 George Staikos <staikos@kde.org> 7 * 2001 George Staikos <staikos@kde.org>
8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved. 8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved.
9 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com> 9 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com>
10 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) 10 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies)
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 return frame.release(); 115 return frame.release();
116 } 116 }
117 117
118 LocalFrame::~LocalFrame() 118 LocalFrame::~LocalFrame()
119 { 119 {
120 setView(nullptr); 120 setView(nullptr);
121 loader().clear(); 121 loader().clear();
122 setDOMWindow(nullptr); 122 setDOMWindow(nullptr);
123 } 123 }
124 124
125 void LocalFrame::willBeDestroyed()
126 {
127 loader().frameDetached();
128 WillBePersistentHeapSupplementable<LocalFrame>::willBeDestroyed();
129 }
130
125 bool LocalFrame::inScope(TreeScope* scope) const 131 bool LocalFrame::inScope(TreeScope* scope) const
126 { 132 {
127 ASSERT(scope); 133 ASSERT(scope);
128 Document* doc = document(); 134 Document* doc = document();
129 if (!doc) 135 if (!doc)
130 return false; 136 return false;
131 // FIXME: This check is broken in for OOPI. 137 // FIXME: This check is broken in for OOPI.
132 HTMLFrameOwnerElement* owner = doc->ownerElement(); 138 HTMLFrameOwnerElement* owner = doc->ownerElement();
133 if (!owner) 139 if (!owner)
134 return false; 140 return false;
(...skipping 521 matching lines...) Expand 10 before | Expand all | Expand 10 after
656 LocalFrame* LocalFrame::localFrameRoot() 662 LocalFrame* LocalFrame::localFrameRoot()
657 { 663 {
658 LocalFrame* curFrame = this; 664 LocalFrame* curFrame = this;
659 while (curFrame && curFrame->tree().parent() && curFrame->tree().parent()->i sLocalFrame()) 665 while (curFrame && curFrame->tree().parent() && curFrame->tree().parent()->i sLocalFrame())
660 curFrame = toLocalFrame(curFrame->tree().parent()); 666 curFrame = toLocalFrame(curFrame->tree().parent());
661 667
662 return curFrame; 668 return curFrame;
663 } 669 }
664 670
665 } // namespace WebCore 671 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698