OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/chromeos/drive/fileapi/file_system_backend_delegate.h" | 5 #include "chrome/browser/chromeos/drive/fileapi/file_system_backend_delegate.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "chrome/browser/chromeos/drive/file_system_util.h" | 10 #include "chrome/browser/chromeos/drive/file_system_util.h" |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 DCHECK_EQ(fileapi::kFileSystemTypeDrive, url.type()); | 66 DCHECK_EQ(fileapi::kFileSystemTypeDrive, url.type()); |
67 | 67 |
68 base::FilePath file_path = util::ExtractDrivePathFromFileSystemUrl(url); | 68 base::FilePath file_path = util::ExtractDrivePathFromFileSystemUrl(url); |
69 // Hosted documents don't support stream writer. | 69 // Hosted documents don't support stream writer. |
70 if (file_path.empty() || util::HasHostedDocumentExtension(file_path)) | 70 if (file_path.empty() || util::HasHostedDocumentExtension(file_path)) |
71 return scoped_ptr<fileapi::FileStreamWriter>(); | 71 return scoped_ptr<fileapi::FileStreamWriter>(); |
72 | 72 |
73 return scoped_ptr<fileapi::FileStreamWriter>( | 73 return scoped_ptr<fileapi::FileStreamWriter>( |
74 new internal::WebkitFileStreamWriterImpl( | 74 new internal::WebkitFileStreamWriterImpl( |
75 base::Bind(&fileapi_internal::GetFileSystemFromUrl, url), | 75 base::Bind(&fileapi_internal::GetFileSystemFromUrl, url), |
76 context->default_file_task_runner(),file_path, offset)); | 76 context->default_file_task_runner(), |
| 77 file_path, |
| 78 offset)); |
| 79 } |
| 80 |
| 81 fileapi::WatcherManager* FileSystemBackendDelegate::GetWatcherManager( |
| 82 const fileapi::FileSystemURL& url) { |
| 83 NOTIMPLEMENTED(); |
| 84 return NULL; |
77 } | 85 } |
78 | 86 |
79 } // namespace drive | 87 } // namespace drive |
OLD | NEW |