OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "ios/chrome/browser/web/chrome_web_client.h" | 5 #include "ios/chrome/browser/web/chrome_web_client.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/files/file_util.h" | 8 #include "base/files/file_util.h" |
9 #include "base/ios/ios_util.h" | 9 #include "base/ios/ios_util.h" |
10 #include "base/mac/bundle_locations.h" | 10 #include "base/mac/bundle_locations.h" |
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
148 void ChromeWebClient::GetAdditionalWebUISchemes( | 148 void ChromeWebClient::GetAdditionalWebUISchemes( |
149 std::vector<std::string>* additional_schemes) { | 149 std::vector<std::string>* additional_schemes) { |
150 additional_schemes->push_back(dom_distiller::kDomDistillerScheme); | 150 additional_schemes->push_back(dom_distiller::kDomDistillerScheme); |
151 } | 151 } |
152 | 152 |
153 void ChromeWebClient::PostBrowserURLRewriterCreation( | 153 void ChromeWebClient::PostBrowserURLRewriterCreation( |
154 web::BrowserURLRewriter* rewriter) { | 154 web::BrowserURLRewriter* rewriter) { |
155 rewriter->AddURLRewriter(&WillHandleWebBrowserAboutURL); | 155 rewriter->AddURLRewriter(&WillHandleWebBrowserAboutURL); |
156 } | 156 } |
157 | 157 |
158 NSString* ChromeWebClient::GetEarlyPageScript() const { | 158 NSString* ChromeWebClient::GetEarlyPageScript( |
| 159 web::BrowserState* browser_state) const { |
159 return GetPageScript(@"print"); | 160 return GetPageScript(@"print"); |
160 } | 161 } |
161 | 162 |
162 void ChromeWebClient::AllowCertificateError( | 163 void ChromeWebClient::AllowCertificateError( |
163 web::WebState* web_state, | 164 web::WebState* web_state, |
164 int cert_error, | 165 int cert_error, |
165 const net::SSLInfo& info, | 166 const net::SSLInfo& info, |
166 const GURL& request_url, | 167 const GURL& request_url, |
167 bool overridable, | 168 bool overridable, |
168 const base::Callback<void(bool)>& callback) { | 169 const base::Callback<void(bool)>& callback) { |
(...skipping 10 matching lines...) Expand all Loading... |
179 // If this call fails, web will fall back to the default params. | 180 // If this call fails, web will fall back to the default params. |
180 *params_vector = | 181 *params_vector = |
181 task_scheduler_util::GetBrowserWorkerPoolParamsFromVariations(); | 182 task_scheduler_util::GetBrowserWorkerPoolParamsFromVariations(); |
182 *index_to_traits_callback = | 183 *index_to_traits_callback = |
183 base::Bind(&task_scheduler_util::BrowserWorkerPoolIndexForTraits); | 184 base::Bind(&task_scheduler_util::BrowserWorkerPoolIndexForTraits); |
184 } | 185 } |
185 | 186 |
186 void ChromeWebClient::PerformExperimentalTaskSchedulerRedirections() { | 187 void ChromeWebClient::PerformExperimentalTaskSchedulerRedirections() { |
187 task_scheduler_util::MaybePerformBrowserTaskSchedulerRedirection(); | 188 task_scheduler_util::MaybePerformBrowserTaskSchedulerRedirection(); |
188 } | 189 } |
OLD | NEW |