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

Unified Diff: chrome/browser/net/chrome_url_request_context.h

Issue 6410115: Adds navigator.registerProtocolHandler. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Sync'd, disallow non-same origin rph, adds hostname to the infobar. Created 9 years, 10 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: chrome/browser/net/chrome_url_request_context.h
diff --git a/chrome/browser/net/chrome_url_request_context.h b/chrome/browser/net/chrome_url_request_context.h
index ef557cf8ead1977f5ea0c72a761d73dc026ce941..8dbf13d753a47ea6dc479ad39843249d6b03d3f4 100644
--- a/chrome/browser/net/chrome_url_request_context.h
+++ b/chrome/browser/net/chrome_url_request_context.h
@@ -13,6 +13,7 @@
#include "chrome/browser/appcache/chrome_appcache_service.h"
#include "chrome/browser/chrome_blob_storage_context.h"
#include "chrome/browser/content_settings/host_content_settings_map.h"
+#include "chrome/browser/custom_handlers/protocol_handler_registry.h"
#include "chrome/browser/extensions/extension_info_map.h"
#include "chrome/browser/extensions/extension_io_event_router.h"
#include "chrome/browser/extensions/extension_webrequest_api.h"
@@ -98,6 +99,10 @@ class ChromeURLRequestContext : public net::URLRequestContext {
return prerender_manager_.get();
}
+ const ProtocolHandlerRegistry* protocol_handler_registry() {
+ return protocol_handler_registry_.get();
+ }
+
ChromeURLDataManagerBackend* GetChromeURLDataManagerBackend();
// Setters to simplify initializing from factory objects.
@@ -137,6 +142,9 @@ class ChromeURLRequestContext : public net::URLRequestContext {
void set_prerender_manager(prerender::PrerenderManager* prerender_manager) {
prerender_manager_ = prerender_manager;
}
+ void set_protocol_handler_registry(ProtocolHandlerRegistry* registry) {
+ protocol_handler_registry_ = registry;
+ }
// Callback for when the accept language changes.
void OnAcceptLanguageChange(const std::string& accept_language);
@@ -164,6 +172,7 @@ class ChromeURLRequestContext : public net::URLRequestContext {
scoped_refptr<ExtensionIOEventRouter> extension_io_event_router_;
scoped_refptr<prerender::PrerenderManager> prerender_manager_;
scoped_ptr<ChromeURLDataManagerBackend> chrome_url_data_manager_backend_;
+ scoped_refptr<ProtocolHandlerRegistry> protocol_handler_registry_;
bool is_off_the_record_;

Powered by Google App Engine
This is Rietveld 408576698