OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/remove_operation_delegate.h" | 5 #include "webkit/browser/fileapi/remove_operation_delegate.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "webkit/browser/fileapi/file_system_context.h" | 8 #include "webkit/browser/fileapi/file_system_context.h" |
9 #include "webkit/browser/fileapi/file_system_operation_runner.h" | 9 #include "webkit/browser/fileapi/file_system_operation_runner.h" |
10 | 10 |
11 namespace fileapi { | 11 namespace storage { |
12 | 12 |
13 RemoveOperationDelegate::RemoveOperationDelegate( | 13 RemoveOperationDelegate::RemoveOperationDelegate( |
14 FileSystemContext* file_system_context, | 14 FileSystemContext* file_system_context, |
15 const FileSystemURL& url, | 15 const FileSystemURL& url, |
16 const StatusCallback& callback) | 16 const StatusCallback& callback) |
17 : RecursiveOperationDelegate(file_system_context), | 17 : RecursiveOperationDelegate(file_system_context), |
18 url_(url), | 18 url_(url), |
19 callback_(callback), | 19 callback_(callback), |
20 weak_factory_(this) { | 20 weak_factory_(this) { |
21 } | 21 } |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
72 | 72 |
73 void RemoveOperationDelegate::DidRemoveFile(const StatusCallback& callback, | 73 void RemoveOperationDelegate::DidRemoveFile(const StatusCallback& callback, |
74 base::File::Error error) { | 74 base::File::Error error) { |
75 if (error == base::File::FILE_ERROR_NOT_FOUND) { | 75 if (error == base::File::FILE_ERROR_NOT_FOUND) { |
76 callback.Run(base::File::FILE_OK); | 76 callback.Run(base::File::FILE_OK); |
77 return; | 77 return; |
78 } | 78 } |
79 callback.Run(error); | 79 callback.Run(error); |
80 } | 80 } |
81 | 81 |
82 } // namespace fileapi | 82 } // namespace storage |
OLD | NEW |