OLD | NEW |
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 #include "webkit/fileapi/file_system_task_runners.h" | 5 #include "webkit/fileapi/file_system_task_runners.h" |
6 | 6 |
7 #include "base/message_loop_proxy.h" | 7 #include "base/message_loop_proxy.h" |
8 #include "base/sequenced_task_runner.h" | |
9 #include "base/single_thread_task_runner.h" | 8 #include "base/single_thread_task_runner.h" |
| 9 #include "base/task/sequenced_task_runner.h" |
10 | 10 |
11 namespace fileapi { | 11 namespace fileapi { |
12 | 12 |
13 const char kMediaTaskRunnerName[] = "media-task-runner"; | 13 const char kMediaTaskRunnerName[] = "media-task-runner"; |
14 | 14 |
15 FileSystemTaskRunners::FileSystemTaskRunners( | 15 FileSystemTaskRunners::FileSystemTaskRunners( |
16 base::SingleThreadTaskRunner* io_task_runner, | 16 base::SingleThreadTaskRunner* io_task_runner, |
17 base::SingleThreadTaskRunner* file_task_runner, | 17 base::SingleThreadTaskRunner* file_task_runner, |
18 base::SequencedTaskRunner* media_task_runner) | 18 base::SequencedTaskRunner* media_task_runner) |
19 : io_task_runner_(io_task_runner), | 19 : io_task_runner_(io_task_runner), |
20 file_task_runner_(file_task_runner), | 20 file_task_runner_(file_task_runner), |
21 media_task_runner_(media_task_runner) { | 21 media_task_runner_(media_task_runner) { |
22 } | 22 } |
23 | 23 |
24 // static | 24 // static |
25 scoped_ptr<FileSystemTaskRunners> | 25 scoped_ptr<FileSystemTaskRunners> |
26 FileSystemTaskRunners::CreateMockTaskRunners() { | 26 FileSystemTaskRunners::CreateMockTaskRunners() { |
27 return make_scoped_ptr(new FileSystemTaskRunners( | 27 return make_scoped_ptr(new FileSystemTaskRunners( |
28 base::MessageLoopProxy::current(), | 28 base::MessageLoopProxy::current(), |
29 base::MessageLoopProxy::current(), | 29 base::MessageLoopProxy::current(), |
30 base::MessageLoopProxy::current())); | 30 base::MessageLoopProxy::current())); |
31 } | 31 } |
32 | 32 |
33 FileSystemTaskRunners::~FileSystemTaskRunners() { | 33 FileSystemTaskRunners::~FileSystemTaskRunners() { |
34 } | 34 } |
35 | 35 |
36 } // namespace fileapi | 36 } // namespace fileapi |
OLD | NEW |