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

Unified Diff: components/html_viewer/html_document.cc

Issue 1149793002: Detach old frame on WebFrame::swap. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: adding comments Created 5 years, 7 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
« no previous file with comments | « components/html_viewer/html_document.h ('k') | components/printing/renderer/print_web_view_helper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/html_viewer/html_document.cc
diff --git a/components/html_viewer/html_document.cc b/components/html_viewer/html_document.cc
index 4f678954e1683bd86c7e6c070b814e99e598b4de..786f6885a643341dc2399e2fe47c8c3c87e570f9 100644
--- a/components/html_viewer/html_document.cc
+++ b/components/html_viewer/html_document.cc
@@ -255,6 +255,11 @@ blink::WebFrame* HTMLDocument::createChildFrame(
}
void HTMLDocument::frameDetached(blink::WebFrame* frame) {
+ frameDetached(frame, DetachType::Remove);
+}
+
+void HTMLDocument::frameDetached(blink::WebFrame* frame, DetachType type) {
+ DCHECK(type == DetachType::Remove);
sky 2015/06/02 23:01:40 nit: DCHECK_EQ
if (frame->parent())
frame->parent()->removeChild(frame);
« no previous file with comments | « components/html_viewer/html_document.h ('k') | components/printing/renderer/print_web_view_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698