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

Unified Diff: components/gcm_driver/fake_gcm_client.cc

Issue 2889683003: Rename TaskRunner::RunsTasksOnCurrentThread() in //components (Closed)
Patch Set: rebase Created 3 years, 6 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 | « components/drive/chromeos/resource_metadata.cc ('k') | components/gcm_driver/gcm_driver_desktop.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/gcm_driver/fake_gcm_client.cc
diff --git a/components/gcm_driver/fake_gcm_client.cc b/components/gcm_driver/fake_gcm_client.cc
index ece564a68c9a825c0f76ce203219f1fc34e02dd5..2f992c52a7082bfcd3df1af9b8439a265c62c057 100644
--- a/components/gcm_driver/fake_gcm_client.cc
+++ b/components/gcm_driver/fake_gcm_client.cc
@@ -86,7 +86,7 @@ void FakeGCMClient::Initialize(
}
void FakeGCMClient::Start(StartMode start_mode) {
- DCHECK(io_thread_->RunsTasksOnCurrentThread());
+ DCHECK(io_thread_->RunsTasksInCurrentSequence());
if (started_)
return;
@@ -109,14 +109,14 @@ void FakeGCMClient::DoStart() {
}
void FakeGCMClient::Stop() {
- DCHECK(io_thread_->RunsTasksOnCurrentThread());
+ DCHECK(io_thread_->RunsTasksInCurrentSequence());
started_ = false;
delegate_->OnDisconnected();
}
void FakeGCMClient::Register(
const linked_ptr<RegistrationInfo>& registration_info) {
- DCHECK(io_thread_->RunsTasksOnCurrentThread());
+ DCHECK(io_thread_->RunsTasksInCurrentSequence());
std::string registration_id;
@@ -149,7 +149,7 @@ bool FakeGCMClient::ValidateRegistration(
void FakeGCMClient::Unregister(
const linked_ptr<RegistrationInfo>& registration_info) {
- DCHECK(io_thread_->RunsTasksOnCurrentThread());
+ DCHECK(io_thread_->RunsTasksInCurrentSequence());
base::ThreadTaskRunnerHandle::Get()->PostTask(
FROM_HERE, base::Bind(&FakeGCMClient::UnregisterFinished,
@@ -159,7 +159,7 @@ void FakeGCMClient::Unregister(
void FakeGCMClient::Send(const std::string& app_id,
const std::string& receiver_id,
const OutgoingMessage& message) {
- DCHECK(io_thread_->RunsTasksOnCurrentThread());
+ DCHECK(io_thread_->RunsTasksInCurrentSequence());
base::ThreadTaskRunnerHandle::Get()->PostTask(
FROM_HERE, base::Bind(&FakeGCMClient::SendFinished,
@@ -236,7 +236,7 @@ void FakeGCMClient::RemoveHeartbeatInterval(const std::string& scope) {
}
void FakeGCMClient::PerformDelayedStart() {
- DCHECK(ui_thread_->RunsTasksOnCurrentThread());
+ DCHECK(ui_thread_->RunsTasksInCurrentSequence());
io_thread_->PostTask(
FROM_HERE,
@@ -245,7 +245,7 @@ void FakeGCMClient::PerformDelayedStart() {
void FakeGCMClient::ReceiveMessage(const std::string& app_id,
const IncomingMessage& message) {
- DCHECK(ui_thread_->RunsTasksOnCurrentThread());
+ DCHECK(ui_thread_->RunsTasksInCurrentSequence());
io_thread_->PostTask(
FROM_HERE,
@@ -256,7 +256,7 @@ void FakeGCMClient::ReceiveMessage(const std::string& app_id,
}
void FakeGCMClient::DeleteMessages(const std::string& app_id) {
- DCHECK(ui_thread_->RunsTasksOnCurrentThread());
+ DCHECK(ui_thread_->RunsTasksInCurrentSequence());
io_thread_->PostTask(
FROM_HERE,
« no previous file with comments | « components/drive/chromeos/resource_metadata.cc ('k') | components/gcm_driver/gcm_driver_desktop.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698