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

Side by Side Diff: content/browser/fileapi/upload_file_system_file_element_reader.cc

Issue 908833002: Move some file api files to fileapi folder (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 9 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
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 "content/browser/fileapi/upload_file_system_file_element_reader.h" 5 #include "content/browser/fileapi/upload_file_system_file_element_reader.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
11 #include "base/numerics/safe_conversions.h" 11 #include "base/numerics/safe_conversions.h"
12 #include "net/base/net_errors.h" 12 #include "net/base/net_errors.h"
13 #include "storage/browser/blob/file_stream_reader.h" 13 #include "storage/browser/fileapi/file_stream_reader.h"
14 #include "storage/browser/fileapi/file_system_context.h" 14 #include "storage/browser/fileapi/file_system_context.h"
15 #include "storage/browser/fileapi/file_system_url.h" 15 #include "storage/browser/fileapi/file_system_url.h"
16 16
17 namespace content { 17 namespace content {
18 18
19 UploadFileSystemFileElementReader::UploadFileSystemFileElementReader( 19 UploadFileSystemFileElementReader::UploadFileSystemFileElementReader(
20 storage::FileSystemContext* file_system_context, 20 storage::FileSystemContext* file_system_context,
21 const GURL& url, 21 const GURL& url,
22 uint64 range_offset, 22 uint64 range_offset,
23 uint64 range_length, 23 uint64 range_length,
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 int result) { 112 int result) {
113 if (result > 0) { 113 if (result > 0) {
114 position_ += result; 114 position_ += result;
115 DCHECK_LE(position_, GetContentLength()); 115 DCHECK_LE(position_, GetContentLength());
116 } 116 }
117 if (!callback.is_null()) 117 if (!callback.is_null())
118 callback.Run(result); 118 callback.Run(result);
119 } 119 }
120 120
121 } // namespace content 121 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/fileapi/local_file_stream_reader_unittest.cc ('k') | content/public/test/test_file_system_backend.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698