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 "webkit/browser/fileapi/file_system_context.h" | 5 #include "webkit/browser/fileapi/file_system_context.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/single_thread_task_runner.h" | 8 #include "base/single_thread_task_runner.h" |
9 #include "base/stl_util.h" | 9 #include "base/stl_util.h" |
10 #include "base/task_runner_util.h" | 10 #include "base/task_runner_util.h" |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 base::SequencedTaskRunner* file_task_runner, | 101 base::SequencedTaskRunner* file_task_runner, |
102 ExternalMountPoints* external_mount_points, | 102 ExternalMountPoints* external_mount_points, |
103 quota::SpecialStoragePolicy* special_storage_policy, | 103 quota::SpecialStoragePolicy* special_storage_policy, |
104 quota::QuotaManagerProxy* quota_manager_proxy, | 104 quota::QuotaManagerProxy* quota_manager_proxy, |
105 ScopedVector<FileSystemBackend> additional_backends, | 105 ScopedVector<FileSystemBackend> additional_backends, |
106 const base::FilePath& partition_path, | 106 const base::FilePath& partition_path, |
107 const FileSystemOptions& options) | 107 const FileSystemOptions& options) |
108 : io_task_runner_(io_task_runner), | 108 : io_task_runner_(io_task_runner), |
109 default_file_task_runner_(file_task_runner), | 109 default_file_task_runner_(file_task_runner), |
110 quota_manager_proxy_(quota_manager_proxy), | 110 quota_manager_proxy_(quota_manager_proxy), |
111 sandbox_context_(new SandboxContext( | 111 sandbox_delegate_(new SandboxFileSystemBackendDelegate( |
112 quota_manager_proxy, | 112 quota_manager_proxy, |
113 file_task_runner, | 113 file_task_runner, |
114 partition_path, | 114 partition_path, |
115 special_storage_policy, | 115 special_storage_policy, |
116 options)), | 116 options)), |
117 sandbox_backend_(new SandboxFileSystemBackend( | 117 sandbox_backend_(new SandboxFileSystemBackend( |
118 sandbox_context_.get())), | 118 sandbox_delegate_.get())), |
119 isolated_backend_(new IsolatedFileSystemBackend()), | 119 isolated_backend_(new IsolatedFileSystemBackend()), |
120 additional_backends_(additional_backends.Pass()), | 120 additional_backends_(additional_backends.Pass()), |
121 external_mount_points_(external_mount_points), | 121 external_mount_points_(external_mount_points), |
122 partition_path_(partition_path), | 122 partition_path_(partition_path), |
123 operation_runner_(new FileSystemOperationRunner(this)) { | 123 operation_runner_(new FileSystemOperationRunner(this)) { |
124 if (quota_manager_proxy) { | 124 if (quota_manager_proxy) { |
125 quota_manager_proxy->RegisterClient(CreateQuotaClient( | 125 quota_manager_proxy->RegisterClient(CreateQuotaClient( |
126 this, options.is_incognito())); | 126 this, options.is_incognito())); |
127 } | 127 } |
128 | 128 |
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
439 FileSystemType type = static_cast<FileSystemType>(t); | 439 FileSystemType type = static_cast<FileSystemType>(t); |
440 if (backend->CanHandleType(type)) { | 440 if (backend->CanHandleType(type)) { |
441 const bool inserted = backend_map_.insert( | 441 const bool inserted = backend_map_.insert( |
442 std::make_pair(type, backend)).second; | 442 std::make_pair(type, backend)).second; |
443 DCHECK(inserted); | 443 DCHECK(inserted); |
444 } | 444 } |
445 } | 445 } |
446 } | 446 } |
447 | 447 |
448 } // namespace fileapi | 448 } // namespace fileapi |
OLD | NEW |