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

Unified Diff: mojo/public/cpp/bindings/interface_ptr.h

Issue 2608163003: Change single-interface mojo bindings to use SequencedTaskRunner. (Closed)
Patch Set: Created 3 years, 11 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
« no previous file with comments | « mojo/public/cpp/bindings/interface_endpoint_client.h ('k') | mojo/public/cpp/bindings/interface_request.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/public/cpp/bindings/interface_ptr.h
diff --git a/mojo/public/cpp/bindings/interface_ptr.h b/mojo/public/cpp/bindings/interface_ptr.h
index 4db5e674c4c09a50e074b110856c0d7a24ec82c5..8d812ab6d73f90ab4a273c2228f6c603eb8d47f9 100644
--- a/mojo/public/cpp/bindings/interface_ptr.h
+++ b/mojo/public/cpp/bindings/interface_ptr.h
@@ -14,8 +14,8 @@
#include "base/logging.h"
#include "base/macros.h"
#include "base/memory/ref_counted.h"
-#include "base/single_thread_task_runner.h"
-#include "base/threading/thread_task_runner_handle.h"
+#include "base/sequenced_task_runner.h"
+#include "base/threading/sequenced_task_runner_handle.h"
#include "mojo/public/cpp/bindings/connection_error_callback.h"
#include "mojo/public/cpp/bindings/interface_ptr_info.h"
#include "mojo/public/cpp/bindings/lib/interface_ptr_state.h"
@@ -78,8 +78,8 @@ class InterfacePtr {
// multiple task runners to a single thread for the purposes of task
// scheduling.
void Bind(InterfacePtrInfo<Interface> info,
- scoped_refptr<base::SingleThreadTaskRunner> runner =
- base::ThreadTaskRunnerHandle::Get()) {
+ scoped_refptr<base::SequencedTaskRunner> runner =
+ base::SequencedTaskRunnerHandle::Get()) {
reset();
if (info.is_valid())
internal_state_.Bind(std::move(info), std::move(runner));
@@ -236,8 +236,8 @@ class InterfacePtr {
template <typename Interface>
InterfacePtr<Interface> MakeProxy(
InterfacePtrInfo<Interface> info,
- scoped_refptr<base::SingleThreadTaskRunner> runner =
- base::ThreadTaskRunnerHandle::Get()) {
+ scoped_refptr<base::SequencedTaskRunner> runner =
+ base::SequencedTaskRunnerHandle::Get()) {
InterfacePtr<Interface> ptr;
if (info.is_valid())
ptr.Bind(std::move(info), std::move(runner));
« no previous file with comments | « mojo/public/cpp/bindings/interface_endpoint_client.h ('k') | mojo/public/cpp/bindings/interface_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698