OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/chrome_content_browser_client.h" | 5 #include "chrome/browser/chrome_content_browser_client.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 1050 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1061 hosts->push_back(chrome::kChromeUIThemeHost); | 1061 hosts->push_back(chrome::kChromeUIThemeHost); |
1062 hosts->push_back(chrome::kChromeUIThumbnailHost); | 1062 hosts->push_back(chrome::kChromeUIThumbnailHost); |
1063 hosts->push_back(chrome::kChromeUIThumbnailHost2); | 1063 hosts->push_back(chrome::kChromeUIThumbnailHost2); |
1064 hosts->push_back(chrome::kChromeUIThumbnailListHost); | 1064 hosts->push_back(chrome::kChromeUIThumbnailListHost); |
1065 } | 1065 } |
1066 | 1066 |
1067 net::URLRequestContextGetter* | 1067 net::URLRequestContextGetter* |
1068 ChromeContentBrowserClient::CreateRequestContext( | 1068 ChromeContentBrowserClient::CreateRequestContext( |
1069 content::BrowserContext* browser_context, | 1069 content::BrowserContext* browser_context, |
1070 content::ProtocolHandlerMap* protocol_handlers, | 1070 content::ProtocolHandlerMap* protocol_handlers, |
1071 content::ProtocolHandlerScopedVector protocol_interceptors) { | 1071 content::URLRequestInterceptorScopedVector request_interceptors) { |
1072 Profile* profile = Profile::FromBrowserContext(browser_context); | 1072 Profile* profile = Profile::FromBrowserContext(browser_context); |
1073 return profile->CreateRequestContext(protocol_handlers, | 1073 return profile->CreateRequestContext(protocol_handlers, |
1074 protocol_interceptors.Pass()); | 1074 request_interceptors.Pass()); |
1075 } | 1075 } |
1076 | 1076 |
1077 net::URLRequestContextGetter* | 1077 net::URLRequestContextGetter* |
1078 ChromeContentBrowserClient::CreateRequestContextForStoragePartition( | 1078 ChromeContentBrowserClient::CreateRequestContextForStoragePartition( |
1079 content::BrowserContext* browser_context, | 1079 content::BrowserContext* browser_context, |
1080 const base::FilePath& partition_path, | 1080 const base::FilePath& partition_path, |
1081 bool in_memory, | 1081 bool in_memory, |
1082 content::ProtocolHandlerMap* protocol_handlers, | 1082 content::ProtocolHandlerMap* protocol_handlers, |
1083 content::ProtocolHandlerScopedVector protocol_interceptors) { | 1083 content::URLRequestInterceptorScopedVector request_interceptors) { |
1084 Profile* profile = Profile::FromBrowserContext(browser_context); | 1084 Profile* profile = Profile::FromBrowserContext(browser_context); |
1085 return profile->CreateRequestContextForStoragePartition( | 1085 return profile->CreateRequestContextForStoragePartition( |
1086 partition_path, | 1086 partition_path, |
1087 in_memory, | 1087 in_memory, |
1088 protocol_handlers, | 1088 protocol_handlers, |
1089 protocol_interceptors.Pass()); | 1089 request_interceptors.Pass()); |
1090 } | 1090 } |
1091 | 1091 |
1092 bool ChromeContentBrowserClient::IsHandledURL(const GURL& url) { | 1092 bool ChromeContentBrowserClient::IsHandledURL(const GURL& url) { |
1093 return ProfileIOData::IsHandledURL(url); | 1093 return ProfileIOData::IsHandledURL(url); |
1094 } | 1094 } |
1095 | 1095 |
1096 bool ChromeContentBrowserClient::CanCommitURL( | 1096 bool ChromeContentBrowserClient::CanCommitURL( |
1097 content::RenderProcessHost* process_host, | 1097 content::RenderProcessHost* process_host, |
1098 const GURL& url) { | 1098 const GURL& url) { |
1099 // We need to let most extension URLs commit in any process, since this can | 1099 // We need to let most extension URLs commit in any process, since this can |
(...skipping 1655 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2755 switches::kDisableWebRtcEncryption, | 2755 switches::kDisableWebRtcEncryption, |
2756 }; | 2756 }; |
2757 to_command_line->CopySwitchesFrom(from_command_line, | 2757 to_command_line->CopySwitchesFrom(from_command_line, |
2758 kWebRtcDevSwitchNames, | 2758 kWebRtcDevSwitchNames, |
2759 arraysize(kWebRtcDevSwitchNames)); | 2759 arraysize(kWebRtcDevSwitchNames)); |
2760 } | 2760 } |
2761 } | 2761 } |
2762 #endif // defined(ENABLE_WEBRTC) | 2762 #endif // defined(ENABLE_WEBRTC) |
2763 | 2763 |
2764 } // namespace chrome | 2764 } // namespace chrome |
OLD | NEW |