Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(365)

Side by Side Diff: chrome/browser/chromeos/file_system_provider/fake_provided_file_system.cc

Issue 375543002: [fsp] Add support for deleting entries. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased + cleaned up. Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/file_system_provider/fake_provided_file_system .h" 5 #include "chrome/browser/chromeos/file_system_provider/fake_provided_file_system .h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/files/file.h" 9 #include "base/files/file.h"
10 #include "base/message_loop/message_loop_proxy.h" 10 #include "base/message_loop/message_loop_proxy.h"
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after
229 229
230 void FakeProvidedFileSystem::CreateDirectory( 230 void FakeProvidedFileSystem::CreateDirectory(
231 const base::FilePath& directory_path, 231 const base::FilePath& directory_path,
232 bool exclusive, 232 bool exclusive,
233 bool recursive, 233 bool recursive,
234 const fileapi::AsyncFileUtil::StatusCallback& callback) { 234 const fileapi::AsyncFileUtil::StatusCallback& callback) {
235 base::MessageLoopProxy::current()->PostTask( 235 base::MessageLoopProxy::current()->PostTask(
236 FROM_HERE, base::Bind(callback, base::File::FILE_OK)); 236 FROM_HERE, base::Bind(callback, base::File::FILE_OK));
237 } 237 }
238 238
239 void FakeProvidedFileSystem::DeleteEntry(
240 const base::FilePath& entry_path,
241 bool recursive,
242 const fileapi::AsyncFileUtil::StatusCallback& callback) {
243 base::MessageLoopProxy::current()->PostTask(
244 FROM_HERE, base::Bind(callback, base::File::FILE_OK));
245 }
246
239 const ProvidedFileSystemInfo& FakeProvidedFileSystem::GetFileSystemInfo() 247 const ProvidedFileSystemInfo& FakeProvidedFileSystem::GetFileSystemInfo()
240 const { 248 const {
241 return file_system_info_; 249 return file_system_info_;
242 } 250 }
243 251
244 RequestManager* FakeProvidedFileSystem::GetRequestManager() { 252 RequestManager* FakeProvidedFileSystem::GetRequestManager() {
245 NOTREACHED(); 253 NOTREACHED();
246 return NULL; 254 return NULL;
247 } 255 }
248 256
249 ProvidedFileSystemInterface* FakeProvidedFileSystem::Create( 257 ProvidedFileSystemInterface* FakeProvidedFileSystem::Create(
250 Profile* profile, 258 Profile* profile,
251 const ProvidedFileSystemInfo& file_system_info) { 259 const ProvidedFileSystemInfo& file_system_info) {
252 return new FakeProvidedFileSystem(file_system_info); 260 return new FakeProvidedFileSystem(file_system_info);
253 } 261 }
254 262
255 base::WeakPtr<ProvidedFileSystemInterface> 263 base::WeakPtr<ProvidedFileSystemInterface>
256 FakeProvidedFileSystem::GetWeakPtr() { 264 FakeProvidedFileSystem::GetWeakPtr() {
257 return weak_ptr_factory_.GetWeakPtr(); 265 return weak_ptr_factory_.GetWeakPtr();
258 } 266 }
259 267
260 } // namespace file_system_provider 268 } // namespace file_system_provider
261 } // namespace chromeos 269 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698