| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/fileapi/sandbox_mount_point_provider.h" | 5 #include "webkit/fileapi/sandbox_mount_point_provider.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/memory/scoped_callback_factory.h" | 10 #include "base/memory/scoped_callback_factory.h" |
| (...skipping 415 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 426 // TODO(ericu): Implement this method and check for access permissions as | 426 // TODO(ericu): Implement this method and check for access permissions as |
| 427 // fileBrowserPrivate extension API does. We currently have another mechanism, | 427 // fileBrowserPrivate extension API does. We currently have another mechanism, |
| 428 // but we should switch over. This may also need to call MigrateIfNeeded(). | 428 // but we should switch over. This may also need to call MigrateIfNeeded(). |
| 429 return std::vector<FilePath>(); | 429 return std::vector<FilePath>(); |
| 430 } | 430 } |
| 431 | 431 |
| 432 FileSystemFileUtil* SandboxMountPointProvider::GetFileUtil() { | 432 FileSystemFileUtil* SandboxMountPointProvider::GetFileUtil() { |
| 433 return sandbox_file_util_.get(); | 433 return sandbox_file_util_.get(); |
| 434 } | 434 } |
| 435 | 435 |
| 436 FileSystemOperationInterface* |
| 437 SandboxMountPointProvider::CreateFileSystemOperation( |
| 438 const GURL& url, |
| 439 FileSystemCallbackDispatcher* dispatcher, |
| 440 base::MessageLoopProxy* file_proxy, |
| 441 FileSystemContext* context) const { |
| 442 return new FileSystemOperation(dispatcher, file_proxy, context); |
| 443 } |
| 444 |
| 436 FilePath SandboxMountPointProvider::old_base_path() const { | 445 FilePath SandboxMountPointProvider::old_base_path() const { |
| 437 return profile_path_.Append(kOldFileSystemDirectory); | 446 return profile_path_.Append(kOldFileSystemDirectory); |
| 438 } | 447 } |
| 439 | 448 |
| 440 FilePath SandboxMountPointProvider::new_base_path() const { | 449 FilePath SandboxMountPointProvider::new_base_path() const { |
| 441 return profile_path_.Append(kNewFileSystemDirectory); | 450 return profile_path_.Append(kNewFileSystemDirectory); |
| 442 } | 451 } |
| 443 | 452 |
| 444 FilePath SandboxMountPointProvider::renamed_old_base_path() const { | 453 FilePath SandboxMountPointProvider::renamed_old_base_path() const { |
| 445 return profile_path_.Append(kRenamedOldFileSystemDirectory); | 454 return profile_path_.Append(kRenamedOldFileSystemDirectory); |
| (...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 652 i < file_system_options_->additional_allowed_schemes().size(); | 661 i < file_system_options_->additional_allowed_schemes().size(); |
| 653 ++i) { | 662 ++i) { |
| 654 if (url.SchemeIs( | 663 if (url.SchemeIs( |
| 655 file_system_options_->additional_allowed_schemes()[i].c_str())) | 664 file_system_options_->additional_allowed_schemes()[i].c_str())) |
| 656 return true; | 665 return true; |
| 657 } | 666 } |
| 658 return false; | 667 return false; |
| 659 } | 668 } |
| 660 | 669 |
| 661 } // namespace fileapi | 670 } // namespace fileapi |
| OLD | NEW |