| 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 | 8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All |
| 9 * rights reserved. | 9 * rights reserved. |
| 10 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com> | 10 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com> |
| (...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 384 DCHECK_EQ(FrameLoadTypeReload, loadType); | 384 DCHECK_EQ(FrameLoadTypeReload, loadType); |
| 385 m_navigationScheduler->scheduleReload(); | 385 m_navigationScheduler->scheduleReload(); |
| 386 } | 386 } |
| 387 } | 387 } |
| 388 | 388 |
| 389 void LocalFrame::detach(FrameDetachType type) { | 389 void LocalFrame::detach(FrameDetachType type) { |
| 390 // Note that detach() can be re-entered, so it's not possible to | 390 // Note that detach() can be re-entered, so it's not possible to |
| 391 // DCHECK(!m_isDetaching) here. | 391 // DCHECK(!m_isDetaching) here. |
| 392 m_isDetaching = true; | 392 m_isDetaching = true; |
| 393 | 393 |
| 394 if (isLocalRoot()) |
| 395 m_performanceMonitor->shutdown(); |
| 396 |
| 394 PluginScriptForbiddenScope forbidPluginDestructorScripting; | 397 PluginScriptForbiddenScope forbidPluginDestructorScripting; |
| 395 m_loader.stopAllLoaders(); | 398 m_loader.stopAllLoaders(); |
| 396 // Don't allow any new child frames to load in this frame: attaching a new | 399 // Don't allow any new child frames to load in this frame: attaching a new |
| 397 // child frame during or after detaching children results in an attached | 400 // child frame during or after detaching children results in an attached |
| 398 // frame on a detached DOM tree, which is bad. | 401 // frame on a detached DOM tree, which is bad. |
| 399 SubframeLoadingDisabler disabler(*document()); | 402 SubframeLoadingDisabler disabler(*document()); |
| 400 m_loader.dispatchUnloadEvent(); | 403 m_loader.dispatchUnloadEvent(); |
| 401 detachChildren(); | 404 detachChildren(); |
| 402 | 405 |
| 403 // All done if detaching the subframes brought about a detach of this frame | 406 // All done if detaching the subframes brought about a detach of this frame |
| (...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 926 if (m_frame && m_frame->client() && m_frame->client()->frameBlameContext()) | 929 if (m_frame && m_frame->client() && m_frame->client()->frameBlameContext()) |
| 927 m_frame->client()->frameBlameContext()->Enter(); | 930 m_frame->client()->frameBlameContext()->Enter(); |
| 928 } | 931 } |
| 929 | 932 |
| 930 ScopedFrameBlamer::~ScopedFrameBlamer() { | 933 ScopedFrameBlamer::~ScopedFrameBlamer() { |
| 931 if (m_frame && m_frame->client() && m_frame->client()->frameBlameContext()) | 934 if (m_frame && m_frame->client() && m_frame->client()->frameBlameContext()) |
| 932 m_frame->client()->frameBlameContext()->Leave(); | 935 m_frame->client()->frameBlameContext()->Leave(); |
| 933 } | 936 } |
| 934 | 937 |
| 935 } // namespace blink | 938 } // namespace blink |
| OLD | NEW |