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

Unified Diff: content/public/browser/content_browser_client.h

Issue 187223003: Allow content layer to pass ProtocolInterceptors when we create URLRequestContext (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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/public/browser/content_browser_client.h
diff --git a/content/public/browser/content_browser_client.h b/content/public/browser/content_browser_client.h
index 38a3c6fb4ddf3225d8772bc7663b70cd27ab7ac7..18c837b50db12e944a9d54e6e7c92e089480731a 100644
--- a/content/public/browser/content_browser_client.h
+++ b/content/public/browser/content_browser_client.h
@@ -105,6 +105,10 @@ typedef std::map<
std::string, linked_ptr<net::URLRequestJobFactory::ProtocolHandler> >
ProtocolHandlerMap;
+// A scoped vector of protocol handlers.
+typedef ScopedVector<net::URLRequestJobFactory::ProtocolHandler>
+ ProtocolHandlerScopedVector;
+
// Embedder API (or SPI) for participating in browser logic, to be implemented
// by the client of the content browser. See ChromeContentBrowserClient for the
// principal implementation. The methods are assumed to be called on the UI
@@ -195,7 +199,8 @@ class CONTENT_EXPORT ContentBrowserClient {
// TODO(ajwong): Remove once http://crbug.com/159193 is resolved.
virtual net::URLRequestContextGetter* CreateRequestContext(
BrowserContext* browser_context,
- ProtocolHandlerMap* protocol_handlers);
+ ProtocolHandlerMap* protocol_handlers,
+ ProtocolHandlerScopedVector protocol_interceptors);
// Creates the net::URLRequestContextGetter for a StoragePartition. Should
// only be called once per partition_path per ContentBrowserClient object.
@@ -204,7 +209,8 @@ class CONTENT_EXPORT ContentBrowserClient {
BrowserContext* browser_context,
const base::FilePath& partition_path,
bool in_memory,
- ProtocolHandlerMap* protocol_handlers);
+ ProtocolHandlerMap* protocol_handlers,
+ ProtocolHandlerScopedVector protocol_interceptors);
// Returns whether a specified URL is handled by the embedder's internal
// protocol handlers.

Powered by Google App Engine
This is Rietveld 408576698