OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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 "content/child/fileapi/webfilewriter_base.h" | 5 #include "content/child/fileapi/webfilewriter_base.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "third_party/WebKit/public/platform/WebFileError.h" |
| 9 #include "third_party/WebKit/public/platform/WebFileWriterClient.h" |
8 #include "third_party/WebKit/public/platform/WebURL.h" | 10 #include "third_party/WebKit/public/platform/WebURL.h" |
9 #include "third_party/WebKit/public/web/WebFileError.h" | |
10 #include "third_party/WebKit/public/web/WebFileWriterClient.h" | |
11 #include "webkit/common/fileapi/file_system_util.h" | 11 #include "webkit/common/fileapi/file_system_util.h" |
12 | 12 |
13 using fileapi::PlatformFileErrorToWebFileError; | 13 using fileapi::PlatformFileErrorToWebFileError; |
14 | 14 |
15 namespace content { | 15 namespace content { |
16 | 16 |
17 WebFileWriterBase::WebFileWriterBase(const GURL& path, | 17 WebFileWriterBase::WebFileWriterBase(const GURL& path, |
18 WebKit::WebFileWriterClient* client) | 18 WebKit::WebFileWriterClient* client) |
19 : path_(path), | 19 : path_(path), |
20 client_(client), | 20 client_(client), |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
143 | 143 |
144 void WebFileWriterBase::FinishCancel() { | 144 void WebFileWriterBase::FinishCancel() { |
145 DCHECK(kCancelReceivedWriteResponse == cancel_state_); | 145 DCHECK(kCancelReceivedWriteResponse == cancel_state_); |
146 DCHECK(kOperationNone != operation_); | 146 DCHECK(kOperationNone != operation_); |
147 cancel_state_ = kCancelNotInProgress; | 147 cancel_state_ = kCancelNotInProgress; |
148 operation_ = kOperationNone; | 148 operation_ = kOperationNone; |
149 client_->didFail(WebKit::WebFileErrorAbort); | 149 client_->didFail(WebKit::WebFileErrorAbort); |
150 } | 150 } |
151 | 151 |
152 } // namespace content | 152 } // namespace content |
OLD | NEW |