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

Unified Diff: chrome/browser/background/background_contents.h

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 | « no previous file | chrome/browser/background/background_contents.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/background/background_contents.h
diff --git a/chrome/browser/background/background_contents.h b/chrome/browser/background/background_contents.h
index f5e28039a20fca0817fcd371e5968b75cd72d2b1..0708f1c50297185719c58e6b0f081eda9ecbd704 100644
--- a/chrome/browser/background/background_contents.h
+++ b/chrome/browser/background/background_contents.h
@@ -24,6 +24,7 @@
class Profile;
namespace content {
+class RenderFrameHost;
class SessionStorageNamespace;
};
@@ -121,6 +122,15 @@ class BackgroundContents : public extensions::DeferredStartRenderHost,
// The initial URL to load.
GURL initial_url_;
+ // TODO(lukasza): Remove members below after gathering sufficient UMA data for
+ // https://crbug.com/721947.
+ void DidChangeOpener() override;
+ void TrackPreviousOpener();
+ void OnPreviousOpenerDestroyed();
+ bool IsCurrentOpenerHostedApp();
+ content::RenderFrameHost* previous_opener_ = nullptr;
+ base::WeakPtrFactory<BackgroundContents> weak_factory_;
+
DISALLOW_COPY_AND_ASSIGN(BackgroundContents);
};
« no previous file with comments | « no previous file | chrome/browser/background/background_contents.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698