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

Unified Diff: webkit/fileapi/file_system_file_reader.cc

Issue 10197007: Change webkit/{fileapi,quota} code to use TaskRunner. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fixesz Created 8 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: webkit/fileapi/file_system_file_reader.cc
diff --git a/webkit/fileapi/file_system_file_reader.cc b/webkit/fileapi/file_system_file_reader.cc
index c15a607c76774599a590d180e33af9bba0e0166e..a5c642cffd3ee82dd05302119e04c542616f4141 100644
--- a/webkit/fileapi/file_system_file_reader.cc
+++ b/webkit/fileapi/file_system_file_reader.cc
@@ -5,8 +5,8 @@
#include "webkit/fileapi/file_system_file_reader.h"
#include "base/file_util_proxy.h"
-#include "base/message_loop_proxy.h"
#include "base/platform_file.h"
+#include "base/sequenced_task_runner.h"
#include "net/base/file_stream.h"
#include "net/base/io_buffer.h"
#include "net/base/net_errors.h"
@@ -33,11 +33,11 @@ void ReadAdapter(base::WeakPtr<FileSystemFileReader> reader,
}
FileSystemFileReader::FileSystemFileReader(
- base::MessageLoopProxy* file_thread_proxy,
+ base::SequencedTaskRunner* task_runner,
FileSystemContext* file_system_context,
const GURL& url,
int64 initial_offset)
- : file_thread_proxy_(file_thread_proxy),
+ : task_runner_(task_runner),
michaeln 2012/04/27 22:31:08 ditto, maybe we can pick this 'runner' up from the
kinuko 2012/05/04 19:05:35 Done.
file_system_context_(file_system_context),
url_(url),
initial_offset_(initial_offset),
@@ -55,8 +55,7 @@ int FileSystemFileReader::Read(
return local_file_reader_->Read(buf, buf_len, callback);
DCHECK(!has_pending_create_snapshot_);
FileSystemOperationInterface* operation =
- file_system_context_->CreateFileSystemOperation(
- url_, file_thread_proxy_);
+ file_system_context_->CreateFileSystemOperation(url_);
if (!operation)
return net::ERR_INVALID_URL;
has_pending_create_snapshot_ = true;
@@ -90,7 +89,7 @@ void FileSystemFileReader::DidCreateSnapshot(
snapshot_ref_ = file_ref;
local_file_reader_.reset(
- new LocalFileReader(file_thread_proxy_,
+ new LocalFileReader(task_runner_,
michaeln 2012/04/27 22:31:08 maybe we could use a context_->file_task_runner()
kinuko 2012/05/04 19:05:35 SGTM, done.
platform_path,
initial_offset_,
base::Time()));

Powered by Google App Engine
This is Rietveld 408576698