| 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 2284 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2295 | 2295 |
| 2296 void ChromeContentBrowserClient::GetAdditionalAllowedSchemesForFileSystem( | 2296 void ChromeContentBrowserClient::GetAdditionalAllowedSchemesForFileSystem( |
| 2297 std::vector<std::string>* additional_allowed_schemes) { | 2297 std::vector<std::string>* additional_allowed_schemes) { |
| 2298 ContentBrowserClient::GetAdditionalAllowedSchemesForFileSystem( | 2298 ContentBrowserClient::GetAdditionalAllowedSchemesForFileSystem( |
| 2299 additional_allowed_schemes); | 2299 additional_allowed_schemes); |
| 2300 additional_allowed_schemes->push_back(kChromeUIScheme); | 2300 additional_allowed_schemes->push_back(kChromeUIScheme); |
| 2301 additional_allowed_schemes->push_back(extensions::kExtensionScheme); | 2301 additional_allowed_schemes->push_back(extensions::kExtensionScheme); |
| 2302 } | 2302 } |
| 2303 | 2303 |
| 2304 void ChromeContentBrowserClient::GetAdditionalFileSystemMountPointProviders( | 2304 void ChromeContentBrowserClient::GetAdditionalFileSystemMountPointProviders( |
| 2305 content::BrowserContext* browser_context, |
| 2305 const base::FilePath& storage_partition_path, | 2306 const base::FilePath& storage_partition_path, |
| 2306 quota::SpecialStoragePolicy* special_storage_policy, | |
| 2307 fileapi::ExternalMountPoints* external_mount_points, | |
| 2308 ScopedVector<fileapi::FileSystemMountPointProvider>* additional_providers) { | 2307 ScopedVector<fileapi::FileSystemMountPointProvider>* additional_providers) { |
| 2309 #if !defined(OS_ANDROID) | 2308 #if !defined(OS_ANDROID) |
| 2310 base::SequencedWorkerPool* pool = content::BrowserThread::GetBlockingPool(); | 2309 base::SequencedWorkerPool* pool = content::BrowserThread::GetBlockingPool(); |
| 2311 additional_providers->push_back(new MediaFileSystemMountPointProvider( | 2310 additional_providers->push_back(new MediaFileSystemMountPointProvider( |
| 2312 storage_partition_path, | 2311 storage_partition_path, |
| 2313 pool->GetSequencedTaskRunner(pool->GetNamedSequenceToken( | 2312 pool->GetSequencedTaskRunner(pool->GetNamedSequenceToken( |
| 2314 MediaFileSystemMountPointProvider::kMediaTaskRunnerName)).get())); | 2313 MediaFileSystemMountPointProvider::kMediaTaskRunnerName)).get())); |
| 2315 #endif | 2314 #endif |
| 2316 #if defined(OS_CHROMEOS) | 2315 #if defined(OS_CHROMEOS) |
| 2316 fileapi::ExternalMountPoints* external_mount_points = |
| 2317 content::BrowserContext::GetMountPoints(browser_context); |
| 2317 DCHECK(external_mount_points); | 2318 DCHECK(external_mount_points); |
| 2318 chromeos::CrosMountPointProvider* cros_mount_provider = | 2319 chromeos::CrosMountPointProvider* cros_mount_provider = |
| 2319 new chromeos::CrosMountPointProvider( | 2320 new chromeos::CrosMountPointProvider( |
| 2320 new drive::MountPointProviderDelegate(external_mount_points), | 2321 new drive::MountPointProviderDelegate(browser_context), |
| 2321 special_storage_policy, | 2322 browser_context->GetSpecialStoragePolicy(), |
| 2322 external_mount_points, | 2323 external_mount_points, |
| 2323 fileapi::ExternalMountPoints::GetSystemInstance()); | 2324 fileapi::ExternalMountPoints::GetSystemInstance()); |
| 2324 cros_mount_provider->AddSystemMountPoints(); | 2325 cros_mount_provider->AddSystemMountPoints(); |
| 2325 DCHECK(cros_mount_provider->CanHandleType(fileapi::kFileSystemTypeExternal)); | 2326 DCHECK(cros_mount_provider->CanHandleType(fileapi::kFileSystemTypeExternal)); |
| 2326 additional_providers->push_back(cros_mount_provider); | 2327 additional_providers->push_back(cros_mount_provider); |
| 2327 #endif | 2328 #endif |
| 2328 } | 2329 } |
| 2329 | 2330 |
| 2330 #if defined(OS_POSIX) && !defined(OS_MACOSX) | 2331 #if defined(OS_POSIX) && !defined(OS_MACOSX) |
| 2331 void ChromeContentBrowserClient::GetAdditionalMappedFilesForChildProcess( | 2332 void ChromeContentBrowserClient::GetAdditionalMappedFilesForChildProcess( |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2427 #if defined(USE_NSS) | 2428 #if defined(USE_NSS) |
| 2428 crypto::CryptoModuleBlockingPasswordDelegate* | 2429 crypto::CryptoModuleBlockingPasswordDelegate* |
| 2429 ChromeContentBrowserClient::GetCryptoPasswordDelegate( | 2430 ChromeContentBrowserClient::GetCryptoPasswordDelegate( |
| 2430 const GURL& url) { | 2431 const GURL& url) { |
| 2431 return chrome::NewCryptoModuleBlockingDialogDelegate( | 2432 return chrome::NewCryptoModuleBlockingDialogDelegate( |
| 2432 chrome::kCryptoModulePasswordKeygen, url.host()); | 2433 chrome::kCryptoModulePasswordKeygen, url.host()); |
| 2433 } | 2434 } |
| 2434 #endif | 2435 #endif |
| 2435 | 2436 |
| 2436 } // namespace chrome | 2437 } // namespace chrome |
| OLD | NEW |