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

Unified Diff: content/public/common/content_client.h

Issue 10479023: Simplify how Content*Client interfaces are created. Instead of depending on the embedder to know wh… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: remove unused function declaration Created 8 years, 6 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/public/common/content_client.h
===================================================================
--- content/public/common/content_client.h (revision 140381)
+++ content/public/common/content_client.h (working copy)
@@ -73,13 +73,9 @@
virtual ~ContentClient();
ContentBrowserClient* browser() { return browser_; }
- void set_browser(ContentBrowserClient* c) { browser_ = c; }
ContentPluginClient* plugin() { return plugin_; }
- void set_plugin(ContentPluginClient* p) { plugin_ = p; }
ContentRendererClient* renderer() { return renderer_; }
- void set_renderer(ContentRendererClient* r) { renderer_ = r; }
ContentUtilityClient* utility() { return utility_; }
- void set_utility(ContentUtilityClient* u) { utility_ = u; }
// Sets the currently active URL. Use GURL() to clear the URL.
virtual void SetActiveURL(const GURL& url) {}
@@ -139,7 +135,12 @@
int* sandbox_profile_resource_id) const;
#endif
+ void set_browser_for_testing(ContentBrowserClient* c) { browser_ = c; }
+ void set_renderer_for_testing(ContentRendererClient* r) { renderer_ = r; }
+
private:
+ friend class ContentClientInitializer; // To set these pointers.
+
// The embedder API for participating in browser logic.
ContentBrowserClient* browser_;
// The embedder API for participating in plugin logic.

Powered by Google App Engine
This is Rietveld 408576698