| 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/renderer/chrome_content_renderer_client.h" | 5 #include "chrome/renderer/chrome_content_renderer_client.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 1250 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1261 #if BUILDFLAG(ENABLE_PLUGINS) && BUILDFLAG(ENABLE_EXTENSIONS) | 1261 #if BUILDFLAG(ENABLE_PLUGINS) && BUILDFLAG(ENABLE_EXTENSIONS) |
| 1262 bool ChromeContentRendererClient::IsExtensionOrSharedModuleWhitelisted( | 1262 bool ChromeContentRendererClient::IsExtensionOrSharedModuleWhitelisted( |
| 1263 const GURL& url, const std::set<std::string>& whitelist) { | 1263 const GURL& url, const std::set<std::string>& whitelist) { |
| 1264 const extensions::ExtensionSet* extension_set = | 1264 const extensions::ExtensionSet* extension_set = |
| 1265 extensions::RendererExtensionRegistry::Get()->GetMainThreadExtensionSet(); | 1265 extensions::RendererExtensionRegistry::Get()->GetMainThreadExtensionSet(); |
| 1266 return chrome::IsExtensionOrSharedModuleWhitelisted(url, extension_set, | 1266 return chrome::IsExtensionOrSharedModuleWhitelisted(url, extension_set, |
| 1267 whitelist); | 1267 whitelist); |
| 1268 } | 1268 } |
| 1269 #endif | 1269 #endif |
| 1270 | 1270 |
| 1271 blink::WebSpeechSynthesizer* | 1271 std::unique_ptr<blink::WebSpeechSynthesizer> |
| 1272 ChromeContentRendererClient::OverrideSpeechSynthesizer( | 1272 ChromeContentRendererClient::OverrideSpeechSynthesizer( |
| 1273 blink::WebSpeechSynthesizerClient* client) { | 1273 blink::WebSpeechSynthesizerClient* client) { |
| 1274 return new TtsDispatcher(client); | 1274 return base::MakeUnique<TtsDispatcher>(client); |
| 1275 } | 1275 } |
| 1276 | 1276 |
| 1277 bool ChromeContentRendererClient::AllowPepperMediaStreamAPI( | 1277 bool ChromeContentRendererClient::AllowPepperMediaStreamAPI( |
| 1278 const GURL& url) { | 1278 const GURL& url) { |
| 1279 #if defined(OS_ANDROID) | 1279 #if defined(OS_ANDROID) |
| 1280 return false; | 1280 return false; |
| 1281 #else | 1281 #else |
| 1282 // Allow access for tests. | 1282 // Allow access for tests. |
| 1283 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | 1283 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
| 1284 switches::kEnablePepperTesting)) { | 1284 switches::kEnablePepperTesting)) { |
| (...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1552 | 1552 |
| 1553 RecordYouTubeRewriteUMA(result); | 1553 RecordYouTubeRewriteUMA(result); |
| 1554 return corrected_url.ReplaceComponents(r); | 1554 return corrected_url.ReplaceComponents(r); |
| 1555 } | 1555 } |
| 1556 | 1556 |
| 1557 std::unique_ptr<base::TaskScheduler::InitParams> | 1557 std::unique_ptr<base::TaskScheduler::InitParams> |
| 1558 ChromeContentRendererClient::GetTaskSchedulerInitParams() { | 1558 ChromeContentRendererClient::GetTaskSchedulerInitParams() { |
| 1559 return task_scheduler_util:: | 1559 return task_scheduler_util:: |
| 1560 GetRendererTaskSchedulerInitParamsFromCommandLine(); | 1560 GetRendererTaskSchedulerInitParamsFromCommandLine(); |
| 1561 } | 1561 } |
| OLD | NEW |