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

Unified Diff: Source/core/frame/Frame.cpp

Issue 1041473002: Detach old frame on WebFrame::swap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 9 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
Index: Source/core/frame/Frame.cpp
diff --git a/Source/core/frame/Frame.cpp b/Source/core/frame/Frame.cpp
index 4f95ddfb6d8fea37c74c90f1e9df0369f3e741f3..482762aa50032fbff9c3d9e9f9cc9cea87865858 100644
--- a/Source/core/frame/Frame.cpp
+++ b/Source/core/frame/Frame.cpp
@@ -149,14 +149,15 @@ ChromeClient& Frame::chromeClient() const
return emptyChromeClient();
}
-void Frame::finishSwapFrom(Frame* old)
+void Frame::prepareSwapFrom(Frame* old)
{
WindowProxyManager* oldManager = old->windowProxyManager();
- // FIXME: In the future, the Blink API layer will be calling detach() on the
- // old frame prior to completing the swap. However, detach calls
- // clearForClose() instead of clearForNavigation(). Make sure this doesn't
- // become a no-op when that lands, since it's important to detach the global.
oldManager->clearForNavigation();
+}
+
+void Frame::finishSwapFrom(Frame* old)
+{
+ WindowProxyManager* oldManager = old->windowProxyManager();
windowProxyManager()->takeGlobalFrom(oldManager);
}
« no previous file with comments | « Source/core/frame/Frame.h ('k') | Source/web/WebFrame.cpp » ('j') | Source/web/WebFrame.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698