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

Unified Diff: content/browser/frame_host/render_frame_host_manager.cc

Issue 974723002: OOPIF: Replicate dynamic window.name updates. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed Nasko's nits 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: content/browser/frame_host/render_frame_host_manager.cc
diff --git a/content/browser/frame_host/render_frame_host_manager.cc b/content/browser/frame_host/render_frame_host_manager.cc
index 27a6bf2bfe1a7fcf94dd6566b96e22fcf3b2797d..9c12f1722ab85b47aab4c1c4b0bd9bd4945e6b5b 100644
--- a/content/browser/frame_host/render_frame_host_manager.cc
+++ b/content/browser/frame_host/render_frame_host_manager.cc
@@ -856,6 +856,20 @@ void RenderFrameHostManager::OnDidStopLoading() {
}
}
+void RenderFrameHostManager::OnDidUpdateName(const std::string& name) {
+ // The window.name message may be sent outside of --site-per-process when
+ // report_frame_name_changes renderer preference is set (used by
+ // WebView). Don't send the update to proxies in those cases.
+ if (!base::CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kSitePerProcess))
+ return;
+
+ for (const auto& pair : proxy_hosts_) {
+ pair.second->Send(
+ new FrameMsg_DidUpdateName(pair.second->GetRoutingID(), name));
+ }
+}
+
void RenderFrameHostManager::Observe(
int type,
const NotificationSource& source,
« no previous file with comments | « content/browser/frame_host/render_frame_host_manager.h ('k') | content/browser/site_per_process_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698