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

Unified Diff: content/browser/web_contents/web_contents_impl.cc

Issue 2877333004: UMA for measuring how often 2 or more tabs script the same background contents.
Patch Set: No PostDelayedTask and checking if opener is a hosted app Created 3 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 | « content/browser/web_contents/web_contents_impl.h ('k') | content/public/browser/web_contents_observer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/web_contents/web_contents_impl.cc
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index f74d7ca1513b344cccffa260130142f2121bdc76..889867b219cead1e6a44c6cafe5d441bf97f79c6 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -4928,6 +4928,16 @@ void WebContentsImpl::SetFocusedFrame(FrameTreeNode* node,
frame_tree_.SetFocusedFrame(node, source);
}
+void WebContentsImpl::DidChangeOpener(FrameTreeNode* node,
+ FrameTreeNode* opener) {
+ if (!node->IsMainFrame())
+ return;
+
+ DCHECK_EQ(GetOpener(), opener->current_frame_host());
+ for (auto& observer : observers_)
+ observer.DidChangeOpener();
+}
+
void WebContentsImpl::OnFocusedElementChangedInFrame(
RenderFrameHostImpl* frame,
const gfx::Rect& bounds_in_root_view) {
« no previous file with comments | « content/browser/web_contents/web_contents_impl.h ('k') | content/public/browser/web_contents_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698