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

Side by Side Diff: webkit/browser/blob/local_file_stream_reader.h

Issue 46303005: Fix chrome upload with content uri (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: simplify the change using FILE enum instead of adding a new enum Created 7 years, 1 month 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef WEBKIT_BROWSER_BLOB_LOCAL_FILE_STREAM_READER_H_ 5 #ifndef WEBKIT_BROWSER_BLOB_LOCAL_FILE_STREAM_READER_H_
6 #define WEBKIT_BROWSER_BLOB_LOCAL_FILE_STREAM_READER_H_ 6 #define WEBKIT_BROWSER_BLOB_LOCAL_FILE_STREAM_READER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 void DidSeekFileStream(const net::CompletionCallback& callback, 55 void DidSeekFileStream(const net::CompletionCallback& callback,
56 int64 seek_result); 56 int64 seek_result);
57 void DidOpenForRead(net::IOBuffer* buf, 57 void DidOpenForRead(net::IOBuffer* buf,
58 int buf_len, 58 int buf_len,
59 const net::CompletionCallback& callback, 59 const net::CompletionCallback& callback,
60 int open_result); 60 int open_result);
61 61
62 void DidGetFileInfoForGetLength(const net::Int64CompletionCallback& callback, 62 void DidGetFileInfoForGetLength(const net::Int64CompletionCallback& callback,
63 base::PlatformFileError error, 63 base::PlatformFileError error,
64 const base::PlatformFileInfo& file_info); 64 const base::PlatformFileInfo& file_info);
65 #if defined(OS_ANDROID)
66 // Callback when the length of the content url is retrieved. If the content
67 // url cannot be found, |result| < 0. Otherwise, |result| is be the actual
68 // file size.
69 void DidGetContentUrlLength(const net::Int64CompletionCallback& callback,
70 int64 result);
71 #endif
65 72
66 scoped_refptr<base::TaskRunner> task_runner_; 73 scoped_refptr<base::TaskRunner> task_runner_;
67 scoped_ptr<net::FileStream> stream_impl_; 74 scoped_ptr<net::FileStream> stream_impl_;
68 const base::FilePath file_path_; 75 const base::FilePath file_path_;
69 const int64 initial_offset_; 76 const int64 initial_offset_;
70 const base::Time expected_modification_time_; 77 const base::Time expected_modification_time_;
71 bool has_pending_open_; 78 bool has_pending_open_;
72 base::WeakPtrFactory<LocalFileStreamReader> weak_factory_; 79 base::WeakPtrFactory<LocalFileStreamReader> weak_factory_;
73 }; 80 };
74 81
75 } // namespace webkit_blob 82 } // namespace webkit_blob
76 83
77 #endif // WEBKIT_BROWSER_BLOB_LOCAL_FILE_STREAM_READER_H_ 84 #endif // WEBKIT_BROWSER_BLOB_LOCAL_FILE_STREAM_READER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698