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/test_file_system_backend.h" | 5 #include "webkit/browser/fileapi/test_file_system_backend.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
175 if (require_copy_or_move_validator_) { | 175 if (require_copy_or_move_validator_) { |
176 if (!copy_or_move_file_validator_factory_) | 176 if (!copy_or_move_file_validator_factory_) |
177 *error_code = base::PLATFORM_FILE_ERROR_SECURITY; | 177 *error_code = base::PLATFORM_FILE_ERROR_SECURITY; |
178 return copy_or_move_file_validator_factory_.get(); | 178 return copy_or_move_file_validator_factory_.get(); |
179 } | 179 } |
180 return NULL; | 180 return NULL; |
181 } | 181 } |
182 | 182 |
183 void TestFileSystemBackend::InitializeCopyOrMoveFileValidatorFactory( | 183 void TestFileSystemBackend::InitializeCopyOrMoveFileValidatorFactory( |
184 scoped_ptr<CopyOrMoveFileValidatorFactory> factory) { | 184 scoped_ptr<CopyOrMoveFileValidatorFactory> factory) { |
185 // What purpose is this check serving? | |
vandebo (ex-Chrome)
2013/07/18 17:35:14
nit: remove/resolve this question
Greg Billock
2013/07/30 23:18:31
removing it -- my guess is it is remnant test code
| |
185 if (!require_copy_or_move_validator_) { | 186 if (!require_copy_or_move_validator_) { |
186 DCHECK(!factory); | 187 DCHECK(!factory); |
187 return; | 188 return; |
188 } | 189 } |
189 if (!copy_or_move_file_validator_factory_) | 190 if (!copy_or_move_file_validator_factory_) |
190 copy_or_move_file_validator_factory_ = factory.Pass(); | 191 copy_or_move_file_validator_factory_ = factory.Pass(); |
191 } | 192 } |
192 | 193 |
193 FileSystemOperation* TestFileSystemBackend::CreateFileSystemOperation( | 194 FileSystemOperation* TestFileSystemBackend::CreateFileSystemOperation( |
194 const FileSystemURL& url, | 195 const FileSystemURL& url, |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
233 return quota_util_->GetUpdateObservers(type); | 234 return quota_util_->GetUpdateObservers(type); |
234 } | 235 } |
235 | 236 |
236 void TestFileSystemBackend::AddFileChangeObserver( | 237 void TestFileSystemBackend::AddFileChangeObserver( |
237 FileChangeObserver* observer) { | 238 FileChangeObserver* observer) { |
238 quota_util_->AddFileChangeObserver( | 239 quota_util_->AddFileChangeObserver( |
239 kFileSystemTypeTest, observer, quota_util_->task_runner()); | 240 kFileSystemTypeTest, observer, quota_util_->task_runner()); |
240 } | 241 } |
241 | 242 |
242 } // namespace fileapi | 243 } // namespace fileapi |
OLD | NEW |