| OLD | NEW |
| 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 317 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 328 // will trigger the unload event handlers of any child frames, and those eve
nt | 328 // will trigger the unload event handlers of any child frames, and those eve
nt |
| 329 // handlers might start a new subresource load in this frame. | 329 // handlers might start a new subresource load in this frame. |
| 330 m_loader.stopAllLoaders(); | 330 m_loader.stopAllLoaders(); |
| 331 m_loader.detach(); | 331 m_loader.detach(); |
| 332 document()->detach(); | 332 document()->detach(); |
| 333 // This is the earliest that scripting can be disabled: | 333 // This is the earliest that scripting can be disabled: |
| 334 // - FrameLoader::detach() can fire XHR abort events | 334 // - FrameLoader::detach() can fire XHR abort events |
| 335 // - Document::detach()'s deferred widget updates can run script. | 335 // - Document::detach()'s deferred widget updates can run script. |
| 336 ScriptForbiddenScope forbidScript; | 336 ScriptForbiddenScope forbidScript; |
| 337 m_loader.clear(); | 337 m_loader.clear(); |
| 338 // Clear FrameScheduler again in case it is recreated in scripting. |
| 339 m_frameScheduler.reset(); |
| 338 if (!client()) | 340 if (!client()) |
| 339 return; | 341 return; |
| 340 | 342 |
| 341 client()->willBeDetached(); | 343 client()->willBeDetached(); |
| 342 // Notify ScriptController that the frame is closing, since its cleanup ends
up calling | 344 // Notify ScriptController that the frame is closing, since its cleanup ends
up calling |
| 343 // back to FrameLoaderClient via WindowProxy. | 345 // back to FrameLoaderClient via WindowProxy. |
| 344 script().clearForClose(); | 346 script().clearForClose(); |
| 345 setView(nullptr); | 347 setView(nullptr); |
| 346 willDetachFrameHost(); | 348 willDetachFrameHost(); |
| 347 InspectorInstrumentation::frameDetachedFromParent(this); | 349 InspectorInstrumentation::frameDetachedFromParent(this); |
| (...skipping 466 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 814 m_frame->client()->frameBlameContext()->Enter(); | 816 m_frame->client()->frameBlameContext()->Enter(); |
| 815 } | 817 } |
| 816 | 818 |
| 817 ScopedFrameBlamer::~ScopedFrameBlamer() | 819 ScopedFrameBlamer::~ScopedFrameBlamer() |
| 818 { | 820 { |
| 819 if (m_frame && m_frame->client() && m_frame->client()->frameBlameContext()) | 821 if (m_frame && m_frame->client() && m_frame->client()->frameBlameContext()) |
| 820 m_frame->client()->frameBlameContext()->Leave(); | 822 m_frame->client()->frameBlameContext()->Leave(); |
| 821 } | 823 } |
| 822 | 824 |
| 823 } // namespace blink | 825 } // namespace blink |
| OLD | NEW |