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 "remoting/base/auto_thread_task_runner.h" | 5 #include "remoting/base/auto_thread_task_runner.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 | 10 |
(...skipping 16 matching lines...) Expand all Loading... |
27 | 27 |
28 bool AutoThreadTaskRunner::PostNonNestableDelayedTask( | 28 bool AutoThreadTaskRunner::PostNonNestableDelayedTask( |
29 const tracked_objects::Location& from_here, | 29 const tracked_objects::Location& from_here, |
30 base::OnceClosure task, | 30 base::OnceClosure task, |
31 base::TimeDelta delay) { | 31 base::TimeDelta delay) { |
32 CHECK(task_runner_->PostNonNestableDelayedTask(from_here, std::move(task), | 32 CHECK(task_runner_->PostNonNestableDelayedTask(from_here, std::move(task), |
33 delay)); | 33 delay)); |
34 return true; | 34 return true; |
35 } | 35 } |
36 | 36 |
37 bool AutoThreadTaskRunner::RunsTasksOnCurrentThread() const { | 37 bool AutoThreadTaskRunner::RunsTasksInCurrentSequence() const { |
38 return task_runner_->RunsTasksOnCurrentThread(); | 38 return task_runner_->RunsTasksInCurrentSequence(); |
39 } | 39 } |
40 | 40 |
41 AutoThreadTaskRunner::~AutoThreadTaskRunner() { | 41 AutoThreadTaskRunner::~AutoThreadTaskRunner() { |
42 CHECK(task_runner_->PostTask(FROM_HERE, std::move(stop_task_))); | 42 CHECK(task_runner_->PostTask(FROM_HERE, std::move(stop_task_))); |
43 } | 43 } |
44 | 44 |
45 } // namespace remoting | 45 } // namespace remoting |
OLD | NEW |